Installation
Install @mvd/auth, gather the provider details you need, and choose the entry point that fits your app.
Install the package
npm install @mvd/authpnpm add @mvd/authyarn add @mvd/authUse it in browser apps
@mvd/auth is built for apps that run in the browser.
If your framework renders on the server, keep your auth setup inside client-only code so sign-in runs where your users interact with it.
Bring these details from your provider
Before you start, make sure you have:
- A client ID
- An authorization endpoint URL
- A token endpoint URL
- A redirect URI registered with your provider
Those four values are enough to get your first sign-in flow working.
Choose the entry point that matches your app
| Entry point | Choose it when you want to… |
|---|---|
@mvd/auth | create and manage auth from plain browser code |
@mvd/auth/react | read auth state directly inside React components |
If you use the React hooks, install react in your app as usual.