In PHPStorm, you can force arrays to be declared as []
in the "Code Style" section of Settings.
Is there anyway to do the opposite and force arrays to be declared with array()
? For example, I would like the following:
$myArray = ['one', 'two'];
to become
$myArray = array('one', 'two');
when I reformat a script using the editor.
There's an Intention for this:
Unfortunately there's no way to have it performed automatically on "reformat code".