Is there a shortcut for doing this?
['foo', 'bar']
{ foo: true, bar: false }
// some magic
[
'foo',
'bar'
]
{
foo: true,
bar: false
}
Is there a shortcut for doing this?
['foo', 'bar']
{ foo: true, bar: false }
// some magic
[
'foo',
'bar'
]
{
foo: true,
bar: false
}
There’s nothing built in that will do that, no.
Your best bet would be to either use an external prettifier/formatter of some kind to do this, or install one along with a Sublime package that can use that tool for you to do the job.
I’ve never used it myself, but this seems to be popular and looks like it might do this, though some setup would be required (for example you need to install the external tool yourself; the package just acts as an interface to run it for you): https://packagecontrol.io/packages/HTML-CSS-JS%20Prettify
Thank you! I think my expectation was too specific for a default setup. I will explore formatter options! 