@daveyplate/better-auth-ui

中文文档
3.4.0发布于 2026/03/24MITTypeScriptESM + CJS近 30 天下载 109.1万

Plug & play shadcn/ui components for better-auth

原始使用文档
文档目录8 节
  1. better-auth-ui.com
  2. Sign In
  3. Sign Up
  4. Forgot Password
  5. User Button
  6. Email Template
  7. Settings Cards
  8. License

Better Auth UI

Better Auth UI Logo

better-auth-ui.com

Plug & play shadcn/ui auth components for better-auth.

  • Own Your Auth

Demo - Documentation - Roadmap

☕️ Buy me a coffee


Sign In

Sign In DarkSign In Light

Sign Up

Sign Up DarkSign Up Light

Forgot Password

Forgot Password DarkForgot Password Light

User Button

User Dropdown DarkUser Dropdown Light

Email Template

Email Template DarkEmail Template Light

Settings Cards

Settings Cards DarkSettings Cards Light


Fully customizable!

Coming Soon: API Keys, Organization, and more!

License

This project is licensed under the MIT License. See the LICENSE file for details.

版本与发布记录

@daveyplate/better-auth-ui 共发布 208 个版本,首次发布于 2025/01/06;过去 12 个月发布了 22 个版本。

版本发布日期距今
3.4.0latest2026/03/247 个月前
3.3.152026/01/129 个月前
3.3.142026/01/1010 个月前
3.3.132026/01/1010 个月前
3.3.122026/01/0310 个月前
3.3.112026/01/0210 个月前

关于 @daveyplate/better-auth-ui 的常见问题

@daveyplate/better-auth-ui 是什么?

Plug & play shadcn/ui components for better-auth

如何安装 @daveyplate/better-auth-ui?

在项目目录运行 npm install @daveyplate/better-auth-ui,或使用 pnpm add / yarn add / bun add。它还需要宿主项目提供 peer 依赖:@better-auth/passkey(>=1.4.6)、@captchafox/react(^1.10.0)、@daveyplate/better-auth-tanstack(^1.3.6)、@hookform/resolvers(>=5.2.0)、@instantdb/react(>=0.18.0)、@marsidev/react-turnstile(>=1.1.0)、@radix-ui/react-avatar(>=1.1.0)、@radix-ui/react-checkbox(>=1.1.0)、@radix-ui/react-context(>=1.1.0)、@radix-ui/react-dialog(>=1.1.0)、@radix-ui/react-dropdown-menu(>=2.1.0)、@radix-ui/react-label(>=2.1.0)、@radix-ui/react-primitive(>=2.0.0)、@radix-ui/react-select(>=2.2.0)、@radix-ui/react-separator(>=1.1.0)、@radix-ui/react-slot(>=1.1.0)、@radix-ui/react-tabs(>=1.1.0)、@radix-ui/react-tooltip(>=1.2.0)、@radix-ui/react-use-callback-ref(>=1.1.0)、@radix-ui/react-use-layout-effect(>=1.1.0)、@tanstack/react-query(>=5.66.0)、@triplit/client(>=1.0.0)、@triplit/react(>=1.0.0)、better-auth(^1.4.6)、class-variance-authority(>=0.7.0)、clsx(>=2.1.0)、input-otp(>=1.4.0)、lucide-react(>=0.469.0)、react(>=18.0.0)、react-dom(>=18.0.0)、react-hook-form(>=7.55.0)、sonner(>=1.7.0)、tailwind-merge(>=2.6.0)、tailwindcss(>=3.0.0)、zod(>=3.0.0)。npm 7 及以上与 pnpm 8 及以上默认会自动安装必需的 peer 依赖,Yarn 需要手动安装。

@daveyplate/better-auth-ui 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@daveyplate/better-auth-ui 支持 ESM 还是 CommonJS?

同时提供 ES Module 与 CommonJS 入口,import 和 require() 都可以使用,打包工具会自动选择合适的版本。

@daveyplate/better-auth-ui 可以商用吗?

@daveyplate/better-auth-ui 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@daveyplate/better-auth-ui 的下载量有多少?

根据 npm 官方下载统计,@daveyplate/better-auth-ui 在 2026/10/12 – 2026/11/10 这 30 天内被下载 1,090,909 次,日均约 36,364 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@daveyplate/better-auth-ui 还在维护吗?

最新版本 3.4.0 发布于 2026/03/24(7 个月前);至今共发布 208 个版本,其中过去 12 个月发布了 22 个;首次发布于 2025/01/06。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。