nuxt-x-auth-better
OAuthButton
Single OAuth provider sign-in button that calls loginWithProvider for Better Auth.
OAuthButton
The XAuthOAuthButton component renders a single sign-in button for one OAuth provider. It calls loginWithProvider with the provider id when clicked. Use XAuthOAuthButtonGroup to render all configured providers at once.
Components
<XAuthOAuthButton />
Pass a provider definition to render a styled button for that provider.
<XAuthOAuthButton :provider="{ id: 'google', label: 'Google', icon: 'i-simple-icons-google' }" />
Props
| Prop | Type | Default | Description |
|---|---|---|---|
provider | { id: string, label: string, icon: string } | required | Provider definition with id, display label, and icon class |
loading | boolean | false | Show a loading spinner on the button |
AI Context
component: XAuthOAuthButton
package: "@xenterprises/nuxt-x-auth-better"
use-when: Render a single OAuth provider sign-in button with Better Auth
