Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Laravel Countries Laravel Package

drnd-dev/laravel-countries

View on GitHub
Deep Wiki
Context7

Full Documentation

Very short description

Laravel Countries is a package that provides everything you need to kickstart a new project with comprehensive country information, including translations. Optimized for Laravel, it ensures efficient access and management of country data.

The package stores all data directly in your database, allowing you to easily link it to any other table in a simple and familiar way using Laravelโ€™s Eloquent ORM.

This is a continuation from https://github.com/lwwcas/laravel-countries package with a few updates:

  • Laravel 13.x support added.
  • Added native argument and return types.
  • Dropped Laravel 10, 11 support.
  • Added PHPStan and Laravel pint.

๐ŸŒ Available Languages

We currently support the following languages:

Language Flag Country Number of Countries
Arabic ๐Ÿ‡ธ๐Ÿ‡ฆ Saudi Arabia 25
Dutch ๐Ÿ‡ณ๐Ÿ‡ฑ Netherlands 3
English ๐Ÿ‡ฌ๐Ÿ‡ง United Kingdom 67
German ๐Ÿ‡ฉ๐Ÿ‡ช Germany 6
Italian ๐Ÿ‡ฎ๐Ÿ‡น Italy 4
Latvian ๐Ÿ‡ฎ๐Ÿ‡น Latvia 1
Portuguese ๐Ÿ‡ง๐Ÿ‡ท Brazil 9
Russian ๐Ÿ‡ท๐Ÿ‡บ Russia 4
Spanish ๐Ÿ‡ช๐Ÿ‡ธ Spain 21

๐Ÿš€ Getting Started

Install the package quickly via Composer:

composer require drnd-dev/laravel-countries

And get started with Artisan

php artisan w-countries:install

Usage

You can access all the information in the database with a simple query

use  Lwwcas\LaravelCountries\Models\Country;

Country::whereIso('BR')->first();
Country::whereIsoAlpha3('BRA')->first();
Country::whereSlug('brasil')->first();

Credits

License

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

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
emuniq/filament-browser-notifications
syriable/filament-translator
hungnm28/livewire-form
wenprise/eloquent
crudly/encrypted
fadion/bouncy
cuci/prototurk-sdk
gos/pubsub-router-bundle
cuci/prototurk-sdk-symfony
clementtalleu/easyadmin-markdown-bundle
codeflextech/permission-manager
karnoweb/livewire-datepicker
sayedenam/sayed-dashboard
milito/query-filter
apiboxsym/user-bundle
apiboxsym/health-check-bundle
jayeshmepani/jpl-moshier-ephemeris-php
elnasnato/laraliveui
labrodev/rest-sdk
sampaui/sampaui