Laravel Community Tools by Tighten
Laravel Nova icon Nova Packages
N

Address AutoComplete Field

Readme

Nova Address AutoComplete Field

An address field that autocomplete the user input to show suggested addresses using Google Place service.

Installation

You can install the package in to a Laravel app that uses Nova via composer:

composer require naif/address_autocomplete

Configuration

Publish the package config file:

php artisan vendor:publish --provider="Naif\AddressAutocomplete\FieldServiceProvider"

Configuration will be published at [config/address_autocomplete.php].

Add the following keys to your .env and .env.example:

ADDRESS_AUTOCOMPLETE_API_KEY=

Optional: Set map and address language
ADDRESS_AUTOCOMPLETE_LANGUAGE=fr

If you need a Google Maps API key, you can create an app and enable Places API and create credentials to get your API key https://console.developers.google.com.

Usage:

Add the below to Nova/User.php resource:

AddressAutocomplete::make('Address'),

//You can add a country or countries to autocomplete or leave empty for all.
          
// Specify a single country
AddressAutocomplete::make('Address')
          ->countries('US'),
                
// Specify multiple countries [array]
AddressAutocomplete::make('Address')
          ->countries(['US','AU']),

Package screenshot

Support:

naif@naif.io

https://www.linkedin.com/in/naif

License

The MIT License (MIT). Please see License File for more information.

Back to Top
Added 7 years ago
Last updated 6 Years Ago
Version 1.4
Composer
naif/address_autocomplete
GitHub stars 17
Packagist downloads 22,616

Favorites

10 users favorited

Rating

2.00
(out of 5)
★★★★★
★★★★
★★★
★★
2 ratings

Tags

Brought to you by Tighten

Issues/Feature Requests Stats Package Ideas