react-native-crypto-js
react-native-crypto-js copied to clipboard
_reactNativeCryptoJS.default.HmacSHA256() is not a function
package define this HmacSHA256 function in Documentation but it return this error _reactNativeCryptoJS.default.HmacSHA256() is not a function
I am having this same issue - looks like its not a supported algo? Which makes this not a very good port of CryptoJS
@mzupek I have found solution for this issue in react-native
import like this
const Crypto = require('crypto-js');
and use like this,
Crypto.HmacSHA256(prependedPayload, _SALT);
@MrQureshi I keep getting a haste map cannot resolve module crypto-js error? did you run into this?
I tried all of the suggested remedies?
@mzupek remove your node_module and install again
remove that line where you import you Crypto-js replce with
const Crypto = require('crypto-js');
@MrQureshi -- you can't use crypto-js --- it says core.js
crypto not found when using HmacSHA256
Still having this issue, any workarounds ?