-
-
Notifications
You must be signed in to change notification settings - Fork 36
Replace code for depreciated componentWillMount() #10
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
Conversation
Either React Native Async Storage (Expo), with fallback using @react-native-community/async-storage if no AsyncStorage is provided for backwards compatibility.
…isWT/meteor-react-native into allowAsyncStorageSolutions
Using the [`UNSAFE_componentWillUpdate()`](https://reactjs.org/docs/react-component.html#unsafe_componentwillupdate) version to get throgh React v17.
depreciated code
|
@PolarisWT, have you been able to do any production testing with this PR? |
|
I have been using it locally for development without issue for past few weeks. Not that means it has been tested thoroughly, but I cannot determine other methods to test against other use cases. In my use, it is solid... I'd be happy to test more if you can provide some examples to test against. |
|
Hi @PolarisWT, sorry for the delay in replying. GitHub forgot to notify me about your message. The best recommendation I can make right now is building for Android and iOS in Release mode and testing on a real device. For android, this means building a release apk ( A testing app (simple-todos-react-native) is being built, but isn't quite ready yet. |
|
With my development setup, we are testing on multiple simulated and physical (real) devices (both iOS and Android) as part of our workflow. Using Expo which handles the bundling and generation of production ready .ipa and .apk for installs on local devices. Again, we are not ready to publish production so they are not signed - but I haven't experienced any issues from dev testing to production just from using a signed bundle. I was wondering if there were tests that you could determine if moving this code earlier in the Mounting lifecycle would change anything. I haven't seen any undetermined outcomes in my usage, and plan to develop with it and deploy to production. |
|
Merging this into the |
|
This has been published in beta release |
* Update MFA companion package * Replace code for depreciated componentWillMount() (#10) * Allow other AsyncStorage packages to be used * Allows for option to specify AsyncStorage package... Either React Native Async Storage (Expo), with fallback using @react-native-community/async-storage if no AsyncStorage is provided for backwards compatibility. * Remove commented code * Fix package version * Add "Custom Storage Adapter" to Installation * Update AsyncStorage options * Bump package version to 2.0.2 since no longer a breaking change * Throw an error instead of console error if no AsyncStorage installed * Remove dead code `setItem()` * Temporary solution to depreciated componentWillUpdate... Using the [`UNSAFE_componentWillUpdate()`](https://reactjs.org/docs/react-component.html#unsafe_componentwillupdate) version to get throgh React v17. * Moved code to a constructor to replace componentWillMount()... depreciated code Co-authored-by: Nathaniel Dsouza <nate@kidzideaz.xyz> * Add useTracker function (#17) * Bump dev package version * 2.1.0-beta1 * Removing useTracker.js from dev since author has said it is not ready * Remove useTracker * Remove unnecessary code * add useTracker and rewrite withTracker to use it (#31) fixes #29 * Merge changes from master into dev (#32) * Update MFA companion package (#27) * Create manual.yml * Merge updates from master into dev (#37) * Update MFA companion package (#27) * Create manual.yml * Create stale.yml * Update stale.yml * Update index.js * Add a semicolon * Remove unused assignment to options (#34) * Remove unused assignment to options * Mark SHA256 insufficient as wontfix * Remove unused variable self * Remove unused variable serializedValue * Remove unused state properties loading * Bump package version * Deprecate `Meteor.collection` (lowercase-C) * Update Mongo Docs * Update api.md * Update Accounts Docs * Update Tracker and Verbosity Docs * Start adding table of contents * Refactor to remove require cycle * 2.1.0-beta3 * 2.1.0-beta4 * local: Automaticallly commit changes to storage after .insert, .update, or .remove * Update User.js * 2.1.0-beta5 * Refactor code to remove require cycles * Bump Package Version to 2.1.0-rc1 * Delete shiftleft-analysis.yml * Update package version for release Co-authored-by: Polaris Web Technology <PolarisWT@users.noreply.github.com> Co-authored-by: Sandeep Jain <sandeepjain@users.noreply.github.com> Co-authored-by: EC2 Default User <ec2-user@ip-172-31-90-84.ec2.internal> Co-authored-by: Kelly Copley <copleykj@gmail.com>
Placed code into constructor.
Reference: #4 (comment)