v1.4.0
This release adds complete OAuth authentication through Laravel Socialite, remembers the visitor's last login method, introduces reusable breadcrumb helpers, and strengthens the test and CI workflows.
Highlights
- Users can log in and sign up with OAuth providers such as Google or GitHub, enabled with the new
I_S_AUTH_PROVIDERSenvironment variable. - Provider logins link to existing accounts by verified email or create verified passwordless accounts, while keeping two-factor challenges and terms acceptance in place.
- The login page shows a "Last used" badge on the method the visitor last logged in with.
- Pages can replace or extend their layout's breadcrumb stack with static or reactive breadcrumb helpers.
Added
OAuth providers
- Added the
auth_providersoption toconfig/inertia-start.php, built from the newI_S_AUTH_PROVIDERSenvironment variable. The value is a comma-separated list of Socialite driver names. Providers that are not listed return404on every OAuth route. - Added a
googleentry toconfig/services.php, readingGOOGLE_CLIENT_IDandGOOGLE_CLIENT_SECRET, with{APP_URL}/auth/provider/google/callbackas the redirect URL. AddedI_S_AUTH_PROVIDERS,GOOGLE_CLIENT_ID, andGOOGLE_CLIENT_SECRETto.env.example. - Added
App\Http\Controllers\Auth\OAuthControllerand its routes:GET auth/provider/{provider}/redirect(oauth.redirect) andGET auth/provider/{provider}/callback(oauth.callback) to log in with a provider.GETandPOST auth/provider/{provider}/challenge(oauth.challenge,oauth.challenge.store) to complete a two-factor challenge.POST signup/provider/{provider}/redirect(oauth.registration.redirect) to start from the registration page, andGETandPOST signup/provider/{provider}(oauth.registration,oauth.registration.store) to accept the terms before the account is created. These routes use theguestandfeature:accountsmiddleware.
- Added the
oauth_accountstable, theApp\Models\OAuthAccountmodel, andUser::oauthAccounts(). A provider user ID belongs to a single user, and a user can link one account per provider. - When a provider redirects back to the application:
- An account already linked to the provider user ID is logged in.
- Otherwise, the provider email is matched against existing users, and the provider account is linked on the first login.
- When no user matches, a passwordless account is created with a verified email and the name returned by the provider. The provider is recorded as the context's registration method.
- Providers exposing an
email_verifiedflag, such as Google, must report the email as verified before it is used to match or create an account. - Users with two-factor authentication enabled must enter an authentication app code on the new
auth/OAuthChallengepage. - When
I_S_ACCOUNT_MUST_ACCEPT_TERMSis enabled, new users are sent to the registration page, which shows the provider email as read-only and requires accepting the terms before the account is created.
- Added provider buttons to the login, switch account, and registration pages.
- Added the
AuthProviderTypeScript interface and theauth.oauth.*,messages.last_used,messages.last_used_tooltip,messages.continue_with_provider, andmessages.oauth_providers.githubtranslations in English, Spanish, and French.
Last used login method
- Added a
last_login_methodcookie, kept for one year and configured underlast_login_method_cookieinconfig/inertia-start.php. It is set after logging in with a password, a magic link, a passkey, or an OAuth provider, including the automatic login at the end of registration. - Added
AuthService::rememberLoginMethod()andAuthService::lastUsedLoginMethod(). The latter only returns a built-in method (password,magic_link,passkey) or an enabled provider, and is passed to the login and switch account pages as thelastUsedLoginMethodprop. - Added
App\Http\Responses\PasskeyLoginResponse, bound to the passkeys package'sPasskeyLoginResponsecontract. It responds like the package's default response and also records the passkey login method. - Added the
LastUsedBadgecomponent, displayed with an explanatory tooltip on the matching login button.PasskeyVerifygained alastUsedprop.
Breadcrumbs
- Added
setBreadcrumbItems()to replace a page's breadcrumb stack andaddBreadcrumbItems()to extend the defaults supplied by its layout. - Breadcrumb helpers accept static items or reactive getters, and layout breadcrumb props accept either a replacement array or a resolver that receives the default stack.
AppLayout,AdminLayout, andAccountLayoutnow resolve breadcrumb props consistently; account pages can extend or replace the built-in account breadcrumb.
Tests
- Added feature coverage in
tests/Feature/Auth/OAuthTest.php. - Added frontend unit coverage for replacing, extending, resolving, and reactively updating breadcrumbs.
AuthenticationTestandRegistrationTestnow assert the last used login method cookie after password, magic link, passkey, and post-registration logins.
Changed
- Split the Composer test workflow into
test:backendandtest:browser.composer run testruns both, whilecomposer run ci:checkalso runs ESLint, Prettier,vue-tsc, and the frontend unit tests. - Browser tests now use and clear a dedicated Vite hot file, preventing a stale development server marker from leaking into the test environment.
- CI now installs Node development dependencies explicitly and runs application setup non-interactively.
- Removed generated IDE Helper stubs from Composer, PHPStan, models, and CI. Larastan now infers model properties from migrations, while Laravel-aware editor support provides completion and navigation without generated project files.
- Updated the bundled Inertia Start AI skill to describe the implemented OAuth flow and its security requirements.
TooltipContentnow uses the secondary color for the background instead of the foreground color, and its arrow has a smaller radius. This applies to every tooltip in the application.- Added crawler directives for
/auth/provider/and/signup/provider/to ask crawlers not to visit OAuth endpoints. - Synced with
laravel/vue-starter-kitup to commit4bd3e1d, and documented why Inertia Start intentionally does not adopt every upstream feature.
Fixed
- Made avatar upload and account export tests explicitly enable the avatar feature, preventing environment-dependent failures.
Dependencies
- Added
laravel/socialite5.31. - Removed
barryvdh/laravel-ide-helperto avoid duplicate definitions. This package was previously valuable for completion and navigation, but modern Laravel-aware editor tooling and Larastan now provide those capabilities. - Updated Laravel Framework to 13.32, Laravel Boost to 2.9, Pest to 5.2, Playwright to 1.63, and other minor and patch Composer and npm dependencies.
Upgrade Guide
-
Run
composer install. -
Run
npm install. -
Run
php artisan migrateto create theoauth_accountstable. -
Rebuild frontend assets with
npm run buildor your normal frontend workflow. -
OAuth stays disabled while
I_S_AUTH_PROVIDERSis empty. To enable Google, create an OAuth client in the Google Cloud console with{APP_URL}/auth/provider/google/callbackas an authorized redirect URI, then add its credentials to your.envfile:I_S_AUTH_PROVIDERS=google GOOGLE_CLIENT_ID=your-client-id GOOGLE_CLIENT_SECRET=your-client-secret -
To enable another Socialite provider, add its credentials to
config/services.phpwith{APP_URL}/auth/provider/{provider}/callbackas the redirect URL, add its driver name toI_S_AUTH_PROVIDERS, and addmessages.oauth_providers.{provider}to each locale'smessages.php. Emails from providers that do not expose anemail_verifiedflag are trusted as returned, so only enable providers that return verified email addresses. -
If you customized
resources/js/pages/auth/Login.vue,resources/js/pages/auth/RequestRegistration.vue, orresources/js/components/OAuthProviderButton.vue, merge the provider buttons and last used badges.OAuthProviderButtonnow expects anAuthProviderobject in itsproviderprop instead of a string. -
If you bound your own implementation of
Laravel\Passkeys\Contracts\PasskeyLoginResponse, merge it withApp\Http\Responses\PasskeyLoginResponseand callAuthService::rememberLoginMethod(AuthService::LOGIN_METHOD_PASSKEY), so passkey logins keep being remembered. -
If you customized
resources/js/components/ui/tooltip/TooltipContent.vue, or relied on the previous tooltip colors, review the new styles. -
If you customized
AppLayout,AdminLayout, orAccountLayout, merge the newBreadcrumbItemsPropandresolveBreadcrumbItems()support. Existing static breadcrumb arrays remain supported. -
If you customized the Composer test scripts or GitHub Actions workflow, merge the split backend/browser commands, frontend unit test execution, explicit Node dependency installation, and non-interactive setup.
-
If your editor relied on generated
_ide_helper.php,_ide_helper_models.php, or.phpstorm.meta.phpfiles, enable PhpStorm's bundled Laravel support, Laravel's official VS Code extension, or Laravel's official language server instead.