File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change 1010
1111[ ![ ko-fi] ( https://www.ko-fi.com/img/githubbutton_sm.svg )] ( https://ko-fi.com/R6R3UQ8V )
1212
13- Translate a URI or individual slugs.
14-
1513This package registers a macro for the Laravel ` Translator ` class.
1614This will allow you to translate individual URI slugs, while ignoring parameter placeholders.
15+
1716Parameters will not be translated by this macro. That remains the responsibility of your code.
1817
1918## ✅ Requirements
@@ -31,7 +30,8 @@ composer require codezero/laravel-uri-translator
3130
3231Laravel will automatically register the ServiceProvider.
3332
34- Then in your app's ` lang ` folder, create subdirectories for every locale you want to have translations for.
33+ In your app's ` lang ` folder, create subdirectories for every locale you want to have translations for.
34+
3535Next create a ` routes.php ` file in each of those directories.
3636
3737```
4242 └── routes.php
4343```
4444
45- Return an array of translations from the ` routes.php ` file .
45+ Return an array of translations from the ` routes.php ` files .
4646
4747### 🚀 Usage
4848
@@ -61,7 +61,7 @@ The URI macro accepts 2 additional parameters:
6161Lang::uri('hello/world', 'fr', 'my-package');
6262```
6363
64- You can also use ` trans()->uri('hello/world') ` instead of ` Lang::uri() ` .
64+ You can also use ` trans()->uri('hello/world') ` instead of ` Lang::uri('hello/world' ) ` .
6565
6666### 🔌 Example
6767
You can’t perform that action at this time.
0 commit comments