Update Style CI whitespace check
lasseeee opened this issue · comments
The way this repo is set up to add white space in arrays through Style CI is outdated and should be updated to match how the Laravel repo now does it. There are legitimate reasons not to add the white space, even though it seems to make readability worse.
We prefer with spaces ;)
I understand.
It's not in line with the official files though: https://github.com/laravel/laravel/blob/master/resources/lang/en/validation.php and whenever a new translation key is added that is longer than any of the previous keys, white space would need to be added to all the keys, effectively making it impossible to see which key was the new one, as the current setup of Style CI would probably most if not all the lines in the affected file. This is why this kind of extra white space styling was abandoned.
We are not an official package of Laravel ;)
So I prefer more reactions of community before change something
I'd be surprised if the community would oppose this, as it would align this package (which is made for Laravel) better with Laravel.
@lasseeee, in one of the translation managers it is possible to choose the appearance of the final file.
When this option is set to true
, the resulting file will be nicely formatted with space characters.
When this option is set to false
, the resulting file will not use spaces.
Using this package you can independently control the appearance of the final files and not worry about updating them. The package itself will do as you like 👍
Amazing!
Personally, my opinion is that a formatted array is much easier to read and modify. Therefore, we here prefer to store it in this form. It makes us happy.
You can also use the translation manager, which can save the final file in two versions - with and without formatting.
In my opinion, this is ideal for fans of one of two formats.