@nexusts/auth
v0.9.6
Published
Authentication via better-auth integration
Downloads
1,893
Readme
@nexusts/auth
NexusTS — Bun-native fullstack framework
Description
Authentication via better-auth integration.
Provides authentication via better-auth. Brings the standard adapter so better-auth's API stays consistent with the rest of NexusTS (DI / decorator model). Type-safe users via @CurrentUser, sessions integrated with the framework's session module.
Install
This module is part of the NexusTS monorepo. Each module is published as its own npm package under the @nexusts/ scope.
Most apps start with just the core:
bun add @nexusts/coreThen add this module only if you need it:
bun add @nexusts/authPeer dependencies
bun add better-authbetter-auth^1.6.0 — Authentication provider required by this module.
Without them the module loads but its public methods throw a clear error pointing to this install command on first call.
Usage
import { /* public API */ } from "@nexusts/auth";See the user guide and the example app for a working demo.
License
MIT — see the root LICENSE.
