I18n::translate()
Translates either a given i18n key from global translations or chooses correct entry from array of translations according to the currently set locale
I18n::translate(array|string|null $key, array|string|null $fallback = null, string|null $locale = null): Closure|array|string|null
Parameters
Name | Type | Default |
---|---|---|
$key | array orstring ornull |
no default value |
$fallback | array orstring ornull |
null
|
$locale | string ornull |
null
|
Return types
Closure
orarray
orstring
ornull