Okay, I restarted the application, and today it works.
Laravel Lang in Javascript
Hi everyone,
I installed this laravel-js-localization package in my project:
https://github.com/andywer/laravel-js-localization
I followed every steps but I did not manage to make it work.
My js-localization.php file looks like this, if I understand correctly the following code should let me use the alpha_spaces language tag that is in the validation.php file in my javascript file.
'messages' => [
'validation.alpha_spaces',
],
This is the part where I'm using the package in the blade:
document.write( Lang.get('validation.alpha_spaces') );
But the only thing that it does is write the string 'validation.alpha_spaces' on the blade, it doesn't translate anything.
If you need more explanation let me know.
Thanks in advance.
Please or to participate in this conversation.