-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
0.19 dev #2377
Conversation
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit f156ed4:
|
Size change: +4.06 kB
View unchanged
|
87d35b4
to
d87542b
Compare
Adds support for PointerEvent prop handlers and removes `onClickCapture`. Ref #2377
I've been juggling a dozen things recently and will need more help than in previous releases to canary test changes and find bugs. The canary currently includes many deprecation warnings. I'm also looking for feedback on that. I'm open to a couple of different approaches: Either: 0.19 is released with deprecation warnings in console; 0.20 goes out with all deprecated props/styles removed and no warnings. Or: 0.19 is released with no warnings in console; 0.20 is immediately released with all the warnings in console output; 0.21 removes all the deprecated APIs. cc @EvanBacon for Expo perspective on how disruptive different approaches might be for their SDK users. |
great work, really exciting stuff! |
Trying to use It fails when |
You should create an issue against react-native-paper |
I don't think Are you suggesting I create an issue for the |
Yep. It never did anything on web and shouldn't be imported or used in web components anymore. |
I understand the code doesn't do anything in the web, but it also doesn't do anything in iOS but it is implemented as a no-op: What other reasons is there for removing the BackHandler from the web? I think it sounds like a trade-off between compatibility and maintainability. |
@necolas Would be the solution use conditional import? Wouldn't that make other people's code unnecessarily complex? |
Please create issues against other projects so they have time to make changes before this release goes out. This PR has been open for nearly 6 months, there have been several canary releases, and ample time for testing. The release after this (0.20) will likely remove all the above-mentioned deprecated APIs entirely, so that RNWeb can get significantly smaller and faster. |
I don't think it will be significantly smaller and faster, in-fact it will be easier to wrap this library in the short term than to deal with this compatibility issue in every other project. By all means, remove the deprecated APIs once they are no longer available in RN. Also, correct me if I am wrong. The |
These components have been replaced by Pressable and will be removed from React Native. Fix #2382
Port ScrollView from legacy createReactClass to ES6 Class syntax.
* Add support for 'aria-*' and 'role' props. * Add support for 'id' and 'tabIndex' props. * Add support for 'pointerEvents' and 'userSelect' styles. * Deprecate 'accessibility*' props. * Deprecate 'nativeId' and 'focusable' props. * Deprecate 'pointerEvents' and 'selectable' props. Ref #2379
* Add support for 'enterKeyHint' prop. * Add support for 'inputMode' prop. * Add support for 'readOnly' prop. * Add support for 'rows' prop. * Deprecate 'keyboardType' prop. * Deprecate 'returnKeyType' prop. * Deprecate 'editable' prop. * Deprecate 'numberOfLines' prop. Ref #2379
* Add support for space-separated values. * Deprecate array values. Ref #2379
* Add support for verticalAlign style. * Deprecate textAlignVertical style. Ref #2379
Use space-separated values per W3C standard. Ref #2379
* Support logical styles like 'marginInlineStart' and 'insetInlineStart' via polyfills. * Deprecate non-standard 'marginStart' etc. properties. Ref #2379
This patch reorganizes the style compiler so that the 'preprocess' step is responsible for all the work needed to transform any non-standard CSS from React Native into a form that can be 'compiled' to rules for the CSSStyleSheet. Over time the 'preprocess' step should eventually be unnecessary as React Native aligns its APIs with CSS APIs. And any external style compilers should be able to run the 'preprocess' function over the style input to produce valid CSS as input for the compiler.
Adds support for PointerEvent prop handlers and removes `onClickCapture`. Ref #2377
Match default Text rendering in React Native. Fix #2498
Set textAlign on the default Text element. Prevents inheritance of textAlign set on a parent View. Fix #2498
Latest / last anticipated canary: 0.0.0-47671ca4 Planning to get 0.19 out this week barring any unexpected issues |
Hello @necolas First of all, thanks for this awesome lib, I have been using it for a while and it really rocks! Good job! Regarding the BackHandler, as mentioned above, I believe the purpose of this library is to provide support with react-native. And right now BackHandler is not deprecated on RN. I have tried the latest version (19) for react native web and getting the BackHandler issue. I think it would be nice to reenable support for it, since it is an API that is supported on React Native itself. |
It would be nice align Linking api to RN before 0.19 publish :/ Deprecated Linking listeners still there... and we don't have |
@burakgormek no one reported that issue or submitted a PR. You should do it |
Canary:
npm install react-native-web@0.0.0-47671ca4
Best compatibility:
react-native@>=0.71
React 18 support
createRoot
support.Animated
to support React 18, including newAnimatedColor
node.ScrollView
to Class component for React 18 support.New features
'button'
and'paragraph'
role to equivalent semantic HTML elements.aria-*
props.role
prop.id
prop.tabIndex
prop (only values0
and-1
).pointerEvents
style.userSelect
style.insetInline
.)<Image>
support fortintColor
prop.<TextInput>
support forenterKeyHint
prop.<TextInput>
support forinputMode
prop.<TextInput>
support forreadOnly
prop.<TextInput>
support forrows
prop.Deprecations
Touchable*
components. UsePressable
.Button
component. UsePressable
.StyleSheet.compose()
. Use style array syntax.accessibility*
props. Usearia-*
androle
props.nativeId
prop. Useid
prop.focusable
props. UsetabIndex
prop.pointerEvents
prop. UsepointerEvents
style.selectable
prop. UseuserSelect
style.fontVariant
style array values. Use space-separated string values.textAlignVertical
style. UseverticalAlign
style.transform
style array values. Use space-separated string functions.<Image>
styleresizeMode
. UseresizeMode
prop.<Image>
styletintColor
. UsetintColor
prop.<TextInput>
propkeyboardType
. UseinputMode
prop.<TextInput>
propreturnKeyType
. UseenterKeyHint
prop.<TextInput>
propeditable
. UsereadOnly
prop.<TextInput>
propnumberOfLines
. Userows
prop.Breaking changes
setNativeProps
API.AppState.removeListener
API.Fixes
Animated
now works with compiled styles.Todo:
onPointer*
props.Image
DOM props