Download the PHP package scriptoshi/livewire-google-onetap without Composer
On this page you can find all versions of the php package scriptoshi/livewire-google-onetap. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download scriptoshi/livewire-google-onetap
More information about scriptoshi/livewire-google-onetap
Files in scriptoshi/livewire-google-onetap
Package livewire-google-onetap
Short Description A Laravel Livewire component for Google One Tap authentication
License MIT
Informations about the package livewire-google-onetap
Laravel Livewire Google One Tap
A Laravel Livewire component for Google One Tap authentication. Easily add "Sign in with Google" functionality to your Laravel application with a simple Livewire component.
Installation
You can install the package via composer:
Requirements
This package requires:
- Laravel 12.x
- Livewire 3.x
Configuration
You'll need to set up your Google OAuth credentials in your .env
file:
Database Migration
This package adds Google authentication fields to your users
table. To run the migrations:
Usage
To use the component, make sure you are using laravel 12 starter kit with livewire/volt.
Then, in your login or registration page, add the component:
For registration pages, specify the type:
This component will create automatically load the Google API script, so you don't need to include it separately in your layout.
Example
User Avatar
When users sign in with Google, their Google profile picture URL is stored in the google_avatar_url
field. You can use this to display their profile picture in your application:
This can be particularly useful for creating a consistent user experience when users sign in with Google.
Configure Tailwind CSS
To ensure that Tailwind CSS properly processes the component styles, add this package to your content sources in your CSS file (typically resources/css/app.css
):
For example, your CSS file might look similar to this:
Customization
You can publish the view and modify it, but keep in mind, Google restricts how much you can customize:
Optional Step: If you need to customize the migrations, you can publish them:
Optional Step: If you need to customize the component, you can publish the config:
Styling
The component uses minimal styling and adapts to both light and dark modes. It will automatically detect if your site is using dark mode by checking for the dark
class on the HTML element.
You can customize the width, height, and other aspects by editing the published view.
License
The MIT License (MIT). Please see License File for more information.
All versions of livewire-google-onetap with dependencies
illuminate/support Version ^12.0
illuminate/auth Version ^12.0
livewire/livewire Version ^3.0
laravel/socialite Version ^5.0
google/apiclient Version ^2.12