Files
Gustavo Valverde c2c2fb04bb feat(db)!: make Kysely an optional dependency
Better Auth required Kysely for every install because @better-auth/core declared it a non-optional peer and the main package a hard dependency, even though core used it only for types and the runtime load was already lazy. A Kysely-internal change therefore broke every user's build, including those on Drizzle, Prisma, or Mongo who never touch Kysely.

Sever the coupling: vendor the small structural database-handle types into core so its published types no longer import from kysely; relocate database-type detection to a kysely-free core helper and reach Kysely's value imports only through the already-lazy adapter path; guard that path with a clear error when kysely is absent. Kysely moves to an optional peer dependency. The redundant better-auth/minimal entry is removed, and a bare Kysely Dialect must now be passed as { dialect, type }.
2026-06-07 18:25:23 -07:00
..

Better Auth Core

Core utilities and types for Better Auth — the most comprehensive authentication framework for TypeScript.

Installation

npm install @better-auth/core

Documentation

For full documentation, visit better-auth.com.

License

MIT