Re:Alternative code styles
by eropple on Monday October 15, 2018 @01:34PM
(#18221750)
In JavaScript, imports sometimes (too often, really) have side effects. I don't know if it makes sense for prettier to do that, at least by default.
[ Parent
| on HN ]
Re:Alternative code styles
by michaelmior on Monday October 15, 2018 @04:06PM
(#18223204)
I don't have a problem with anything that discourages imports with side effects. You can always ignore[0] any cases where this happens.
Re:Alternative code styles
by paulddraper on Monday October 15, 2018 @02:13PM
(#18222137)
In my experience, side-effecting imports are fairly uncommon.
But in any cases, all formatters allow you to selectively disable it for certain liners.