prettier-plugin-solidity icon indicating copy to clipboard operation
prettier-plugin-solidity copied to clipboard

Issue with comment inside property chain

Open fvictorio opened this issue 3 years ago • 2 comments

As reported by @wighawag:

This

game.
// CONFIG
config.resolveWindow = 1000;
config.defaultDelay = 0;

gets re-written as:

game.config.resolveWindow = 1000;
// CONFIG
config.defaultDelay = 0;

This seems like a PITA to fix, and I'm not even sure what the "correct" result should be.

fvictorio avatar Feb 10 '22 17:02 fvictorio

I believe this should be formatted as

// CONFIG
game.config.resolveWindow = 1000;
config.defaultDelay = 0;

Will give this a look.

Janther avatar Jul 14 '22 05:07 Janther

Agree, that's what prettier does for the same code in javascript.

fvictorio avatar Jul 15 '22 21:07 fvictorio