@authn-sh/sdk-react
v0.7.1
Published
React bindings and embeddable components for authn.sh.
Readme
@authn-sh/sdk-react
React bindings and embeddable components for authn.sh — <SignIn />, <SignUp />, <UserProfile />, <UserButton />, plus the <AuthnProvider /> wrapper, hooks (useUser, useAuthn, …), and gating components (<SignedIn>, <SignedOut>, <Protect>).
Status: package skeleton.
<AuthnProvider />and stub components ship today; hooks land in JS-6, real component bodies in JS-7, helpers (<UserButton>etc.) in JS-8.
Install
npm install @authn-sh/sdk-react @authn-sh/sdk-js @authn-sh/uiPeer dependencies: react (18 or 19), react-dom (18 or 19).
Subpath exports
| Import | Contents |
| --- | --- |
| @authn-sh/sdk-react | Provider, components, hooks. |
| @authn-sh/sdk-react/components | Just the components. |
| @authn-sh/sdk-react/hooks | Just the hooks. |
| @authn-sh/sdk-react/errors | AuthnError re-export. |
| @authn-sh/sdk-react/types | Type-only re-exports. |
License
AGPL-3.0-only — see LICENSE.
