Comments (2)
In your app.json
your web.output
is set to static
. This means your website is rendered and served as static .html
files. If the file doesn't exist, then you will get a 404.
To use dynamic routes with static rendering, you need to tell the bundler what the possible values of [bar]
could be. This way it will generate the necessary .html
files. https://docs.expo.dev/router/reference/static-rendering/#dynamic-routes
The alternative to static rendering is running your app as a Single Page Application. You can enable this by simply removing output: 'static'
from your app.json
. Now only a index.html
file will be generated. You'll need to run your application via npx serve -s dist
(-s
enables single page mode) and ensure you setup the correct redirect rules in your deployment.
from expo.
Thank you! The second option (removing output: 'static'
and changing to npx serve dist -s
) did the trick for our use case.
(Pre-defining the dynamic routes wouldn't work for us because the dynamic route will be for [user].tsx
pages, and new users can be created after the build)
from expo.
Related Issues (20)
- there is no configuration to disable the analytics firebase auto collection. HOT 1
- What is this request and isn't this too much to ask for? HOT 2
- Browser forward button broken HOT 1
- Expo Notifications : addNotificationResponseReceivedListener HOT 1
- Does expo secure store support sharing data with app extensions? HOT 1
- [SDK 51] expo-image cannot display AVIFs anymore: "Failed to decode image: No codec available" HOT 1
- Known issue: Expo Router / React Navigation crash in SDK 51 when switching tabs (clearSharedTransitionConfigForTag crash) HOT 43
- "Unmatched route" when starting Android app HOT 8
- Bigger Navigation Header is rendering across all screen HOT 2
- Add controls for buffer and cache to expo-video HOT 1
- [docs] expo-location and expo-task-manager HOT 1
- [android][expo-sqlite/next] android build error: Could not find method useDefaultAndroidSdkVersions() for arguments [] on project ':expo-sqlite' of type org.gradle.api.Project HOT 18
- [IOS][expo-modules-core] error: exception specification of overriding function is more lax than base version HOT 14
- IOS Background Fetch HOT 1
- Expo video player issue (Android) with public drive link. HOT 5
- [expo-auth-session]: TikTok deviates from the standard OAuth naming conventions by using `client_key` as the parameter name instead of `client_id` for both the authorization and the token endpoint. HOT 1
- Expo Image Picker Not working on Android 14 SDK 50 HOT 2
- [expo-notifications] setBadgeCountAsync(0) also clears notifications HOT 4
- [expo-contacts] [Android] Contacts.presentFormAsync crashes on Android in SDK 50 HOT 1
- Android crashes when calling launchCameraAsync() HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from expo.