承接 omisai/laravel-countries 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

omisai/laravel-countries

最新稳定版本:v1.0.0

Composer 安装命令:

composer require omisai/laravel-countries

包简介

A Laravel adapter for the countries package.

README 文档

README

Latest Version on Packagist License

Laravel adapter for omisai/php-countries. It registers the Omisai\Countries\Collection in the Laravel service container and exposes it through a facade.

Features

  • Registers Omisai\Countries\Collection as a singleton in the container
  • Resolves the collection by class name or the countries binding
  • Provides a Countries facade
  • Supports Laravel 11, 12, and 13

Requirements

  • PHP 8.2+
  • Laravel 11, 12, or 13

Laravel 13 requires PHP 8.3+, which is enforced by Composer through Laravel's own package constraints.

Installation

Install the package via Composer:

composer require omisai/laravel-countries

Laravel package discovery will register the service provider and facade automatically.

Usage

Resolve the collection from the container:

use Omisai\Countries\Collection;

$countries = app(Collection::class);
$names = $countries->getCountriesName();

Resolve it by binding name:

$countries = app('countries');

Use the facade:

use Omisai\Laravel\Countries\Facades\Countries;

$names = Countries::getCountriesName();
$hungary = Countries::getCountryByAlpha2('HU');

Testing

Run the test suite using Pest:

composer test

Contributing

Please see CONTRIBUTING.md for details on how to contribute to this project.

Security

Please see SECURITY.md for details on reporting security vulnerabilities.

License

This package is open-sourced software licensed under the MIT license.

统计信息

  • 总下载量: 39
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-03-22

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固