@ideem/zsm-react-native
Version:
ZSM makes 2FA easy and invisible for everyone, all the time, using advanced cryptography like MPC to establish cryptographic proof of the origin of any transaction or login attempt, while eliminating opportunities for social engineering. ZSM has no relian
23 lines (16 loc) • 549 B
JavaScript
import WebAuthnClientBase from './webauthn-client-base';
import { NativeModules } from 'react-native';
const { ZSM } = NativeModules;
class WebAuthnClient extends WebAuthnClientBase {
constructor(config) {
super({"installation_description": "React Native", ...config});
}
getZsmApi = async (config) => {
if (!ZSM) {
throw new Error('ZSM native module is not available. Ensure React Native module is properly built and linked.');
}
await ZSM.create(config);
return ZSM;
};
}
export default WebAuthnClient;