Install
Requirements
- PHP 8.2+
- Laravel 11+
Install the package
bash
composer require aaix/laravel-countriesRun migrations
bash
php artisan migrateThat's it. Migrations are auto-loaded by the package's service provider. The following tables are created:
lc_regions,lc_region_translationslc_countries,lc_countries_translationslc_countries_coordinates,lc_countries_geographical,lc_countries_extras
Seed the data
See Seeding for the full story. The short version:
php
// database/seeders/DatabaseSeeder.php
public function run(): void
{
$this->call(\Aaix\LaravelCountries\Database\Seeders\DatabaseSeeder::class);
}bash
php artisan db:seedRe-run it as often as you like — every write is idempotent.
