PHP code example of infinity-it / laravel-dev-tools
1. Go to this page and download the library: Download infinity-it/laravel-dev-tools library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
infinity-it / laravel-dev-tools example snippets
if (!class_exists('\Mohamedhk2\LaravelDevTools\Classes\RegexConfig'))
return [];
use \Mohamedhk2\LaravelDevTools\Classes\RegexConfig;
return [
'scan_paths' => [
app_path(),
resource_path('views'),
...
],
'lang_path' => base_path('lang'),
#
'patterns' => [
new RegexConfig('/(@lang|__|\$t|\$tc)\s*(\(\s*[\'"])([^$]*)([\'"]+\s*(,[^\)]*)*\))/U', 3),
new RegexConfig('/(?:trans|__)\s*\(\s*(?:"((?:[^"]|\\")+)"|\'((?:[^\']|\\\')+)\')\s*(?:,\s*[^)]*\s*)?\)/U', 1, function ($regConf, $out) {
/**
* @var $regConf RegexConfig
*/
return array_values(array_filter(array_merge($out[1], $out[2])));
}),
]
];
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.