Dot notation not supported
vjandrea opened this issue · 6 comments
If i have
'product' => 'Product',
'product.name' => 'Name',
'product.price' => 'Price',
after localization:missing i'll get
'product' => array(
'name' => 'Name',
'price' => 'Price',
),
As you can see the first keyword is lost. Would it be possible to support dot notation, maybe through an option?
Hello,
you cannot use dots in lemma tokens!
localization:missing will parse your code and generate :
trans('product.name')to'product' => array( 'name' => 'product.name' )trans('productname')to'productname' => 'product.name'
I could add an option to unsupport dot notation and keep translations in a flat mode. Is this really what you want?
I think i missed the Laravel documentation part about the dots, i looked now but there's no mention about it.
I use dots just because IMHO it looks cleaner: {{ trans('frontend.product.name') }}
It would be great to have an option that keeps translations in a flat mode. Thanks!
And I think I missed the Laravel documentation part about flat lemma !
I am totally rewritting the extension to support all laravel version, add automatic translations with Bing Translator, add output formatting options (PSR0, 2, etc...) so I will add this option in the next release.
For the end of the month I hope...
Hi !
The new version with your feature is ready. I have totally rewritten the package and added new features like automatic translations with Bing Translator, code style for lang files, etc... Do you want to test it before going on production?
Ok, the new version is released.
You need to change your composer version and set the correct package version according to your laravel version.