Closed jneterer closed 3 years ago
This is looking good so far! Could you please update the README so that the instructions that are now no longer necessary no longer appear there?
Okay, I've just tested it: The patch overwrites userbase's /lib/Crypto/sha-256.js
file. This file won't be executed because in userbase's package.json is a main
entry which points to the /dist/userbase.cjs.js
file. So the patch should either overwrite /dist/userbase.cjs.js
or change the main
entry in the package.json
file.
@Fubinator Okay the PR is updated. I merged your master
with my PR and ran some quick tests. Performing sign in 10 times took 10.86, 11.086, 11.567, 13.65, 10.992, 10.246, 13.455, 10.992, 10.7, and 11.997 seconds, respectively.
@jneterer Thank you very much! Signing in takes about 3x as long for me, as I said. I will try to investigate this further. I'm not sure if it's the emulator or some implementations are very slow. However, I am happy that we both can now at least already sign in :smile:
Adding
patch-package
to manage local dependency code changes. This is used to modify Userbase's hash algorithm name, changing it to lowercasesha-256
to work with browserify-sign which is used by rn-nodeify. The change will be made automatically when installing dependencies, triggered by thepostinstall
script inpackage.json
.Also updating
rn-nodeify
to 10.3.0 which includes a PR from @Fubinator.