Common
설치
애플리케이션 현지화에 필요한 모든 의존성을 빠르게 업데이트할 수 있으므로 Common 패키지 사용을 권장합니다.
Common 패키지의 호환성 표를 참조하세요.
Composer로 패키지를 설치할 수 있습니다.
composer require laravel-lang/common:^6.9
Laravel 10을 사용한다면 설치할 laravel-lang/lang 패키지의 버전을 수동으로 지정해야 합니다.
composer require --dev laravel-lang/lang:^15.39.1:^14.0
사용법
이제 lang:update 콘솔 명령으로 기존 로캘을 업데이트할 수 있습니다.
php artisan lang:update
composer.json의 scripts 블록에서 post-update-cmd 항목에 호출을 추가하는 것도 좋습니다.
{
"scripts": {
"post-update-cmd": [
"@php artisan vendor:publish --tag=laravel-assets --ansi --force",
"@php artisan lang:update"
]
}
}
이렇게 하면 의존성을 업데이트한 뒤 php artisan lang:update 콘솔 명령을 수동으로 실행할 필요 없이 로캘 파일을 자동으로 갱신합니다.
호환성
Laravel | PHP | 패키지 | 의존성 | 상태 |
|---|---|---|---|---|
10*, 11, 12, 13 | 8.1, 8.2, 8.3, 8.4, 8.5 |
| Starter Kits 1, Models 1, Routes 1, Locales 2, Publisher 16, Lang 13-15, Actions 1, Attributes 2, HTTP Statuses 3, Locales 2, JSON Fallback 2, MoonShine 1(관리자 패널 v3) | supported * Laravel 10에서 사용한다면 설치할 Lang 패키지의 버전을 수동으로 지정해야 합니다. |
10*, 11, 12 | 8.1, 8.2, 8.3, 8.4 |
| Models 1, Routes 1, Locales 2, Publisher 16, Lang 13-15, Actions 1, Attributes 2, HTTP Statuses 3, Locales 2, JSON Fallback 2, MoonShine 1(관리자 패널 v3) | not supported * Laravel 10에서 사용한다면 설치할 Lang 패키지의 버전을 수동으로 지정해야 합니다. |
10*, 11 | 8.1, 8.2, 8.3, 8.4 |
| Models 1, Routes 1, Locales 2, Publisher 16, Lang 13-15, Actions 1, Attributes 2, HTTP Statuses 3, Locales 2, JSON Fallback 2 | not supported * Laravel 10에서 사용한다면 설치할 Lang 패키지의 버전을 수동으로 지정해야 합니다. |
10 | 8.1, 8.2, 8.3 |
| Publisher 15, Lang 13, Actions 1, Attributes 2, HTTP Statuses 3, Locales 1 | not supported |
10 | 8.1, 8.2 |
| Publisher 14, Lang 13, Attributes 2, HTTP Statuses 3, Locales 1 | not supported |
8, 9, 10 | 8.1, 8.2 |
| Publisher 14, Lang 12, Attributes 2, HTTP Statuses 3 | not supported |
7, 8, 9 | 8.0, 8.1 |
| Publisher 13, Lang 10, Attributes 1, HTTP Statuses 2 | not supported |
7, 8, 9 | 7.3, 7.4, 8.0, 8.1 |
| Publisher 12, Lang 10, Attributes 1, HTTP Statuses 2 | not supported |