You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+21-7Lines changed: 21 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -57,21 +57,35 @@ php artisan translation:scan
57
57
```
58
58
59
59
60
-
## Customization
60
+
## Configuration
61
61
62
-
### Publishing the configuration
63
-
64
-
You can change the default paths to scan your application from, the output directory where your JSON translation files are located, and even the file extensions you want to scan from.
Then in the `config/translation-helper.php` you can change default values of `scan_directories`, `file_extensions`, `output_directory` and `translation_methods`.
70
+
It will bring you `config/translation-helper.php` configuration file.
71
+
72
+
Read the following sections of what you can configure.
73
+
74
+
### Directories
75
+
76
+
To specify where you want to scan for translation strings, just modify `scan_directories` array:
77
+
```php
78
+
/**
79
+
* Directories to scan for missing translation keys.
80
+
*/
81
+
'scan_directories' => [
82
+
app_path(),
83
+
resource_path('views'),
84
+
resource_path('assets'),
85
+
],
86
+
```
73
87
74
-
### Extending file extensions
88
+
### File extensions
75
89
76
90
Our package scans only `.php` files out of the box.
77
91
@@ -87,7 +101,7 @@ You can add more file extensions to `file_extensions` array in the `config/trans
87
101
],
88
102
```
89
103
90
-
### Modifying translation helper methods
104
+
### Translation helper methods
91
105
92
106
By default our package looks for `lang` and `__` translation helper methods or mixins.
0 commit comments