React Native Azure AD B2C solution using Pure JS. If you are using expo you dont need to eject.
Thanks to https://github.com/sonyarouje/react-native-ad-b2c and https://github.com/wkh237/react-native-azure-ad packages for the inspiration.
Feel free to contribute or sponsor. :)
Note: The version 2.X is not compatible with 1.X version. For 1.x docs, visit https://www.npmjs.com/package/ad-b2c-react-native -> Versions
Create a fork and after cloning locally, do following
- Yarn install
- Create packages/b2c-sample/env/config.js with following
export default config = {
authTenant: "<B2CTenantID>",
authAppId: "<B2CAppID>",
};
- Add your changes to packages/lib
- Run packages/b2c-sample to do runtime test, by
//cmd in root folder
yarn start
//for more options: root -> package.json -> scripts
Don't forget to install peer dependencies "expo-web-browser": "^10.1.0", "react": "^17.0.1"
npm i ad-b2c-react-native -S