Comments (12)
FYI. I tried Navigator but it didn't work for me.
So I created a SimpleNavigator below which works across platforms & will keep improving it:
https://github.com/rhinos-app/rhinos-app-dev/blob/master/App/View/App.js
from react-native-web.
I don't yet see how Navigator (no support for url state) makes sense on web, or would be preferable to react-router.
from react-native-web.
I don't yet see how Navigator (no support for url state) makes sense on web
may be we don't need urls all the time!( because mobile app users are fine with it)
from react-native-web.
That's not the majority case for web
from react-native-web.
Going to close this for now, as react-router is a better choice:
- react-router intends to support React Native
- react-router can be used to control navigation of URL-less apps built with web technologies
- bh5-js/react-navigator doesn't support URLs
- bh5-js/react-navigator has no tests or active development
from react-native-web.
React Router is not going to support React Native remix-run/react-router#743
from react-native-web.
What about adding the "new" NavigationExperimental?
from react-native-web.
The missing part is NavigationStateUtils which is similar to the history api but different
from react-native-web.
I agree with @necolas. Even though that's what the mobile app world looks like today, the URL is within the very fabric of our web and it shouldn't be taken away. Often people tend to take URLs for granted and advantages are not so pronounced.
I admit the native app ecosystem is not web-like, and you can argue that URLs aren't necessary and most people don't care, or so I thought until I put the URL-centric design in my native development toolbox.
I've just open sourced react-router-native that brings native support to react-router. Not sure if this is useful to you guys at the moment as it's under active development, but it's worth a look—and feedback is greatly appreciated.
🍺
from react-native-web.
@jmurzy cool, have you tried the Example you show with react-native-web? It should work on Native and on the Web.
Personally i think the urls are still important, because allow to restore an app state without user interaction
from react-native-web.
@grigio I haven't had a chance to try it with react-native-web. Let me know if you take a stab at it first.
Something to keep in mind is that react-router-native introduces two new route configuration elements to react-router, namely, <Tabs />
Route and <Stack />
Route. We have to test the behavior of these in the browser before making any promises.
🍺
from react-native-web.
@jmurzy react-router-native sounds promising. What is the current state of play? Is it usable by a react newbie?
Best wishes, Max
from react-native-web.
Related Issues (20)
- Vite in a SSR context HOT 7
- CSS Style not Inline
- Add "use client" directive for a proper usage with Next App Router HOT 3
- `AppState.isAvailable` is a string instead of a boolean
- When releasing a new version, create a new GitHub "release" HOT 1
- [Feature Request] add support for onTextLayout props of Text component (Reiterating it once again) HOT 1
- Pressable's onPress method is not triggered by "enter" key when role="link" HOT 1
- How to use types mentioned inside react native inside react-native-web app ?
- React 19 support HOT 1
- `flex:0` still does not respect element size HOT 1
- How to use types interfaces mentioned inside react native inside react-native-web app ?
- Image should support BorderPropTypes HOT 1
- Type error in docs for TextInput
- Crash if TouchableHighlight has a div as a child HOT 2
- Screen Reader Does Not Announce Disabled Elements on Web
- Appearance.setColorScheme not workin in RN Web
- TextInput with selectTextOnFocus sometimes refocuses itself even after losing focus
- Position fixed doesnt work on ios webview
- Error: export 'useAnimatedValue' (imported as 'useAnimatedValue') was not found in 'react-native'
- Suggestion: A more reliable way to check if image is in the cache
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 react-native-web.