dfinity / prettier-plugin-motoko

A code formatter for the Motoko smart contract language.
Apache License 2.0
28 stars 1 forks source link

multiline concatenated string formatted into one very long line #68

Closed letmejustputthishere closed 1 year ago

letmejustputthishere commented 2 years ago

using the experimental LS with dfx 0.11.2 the following happens

Screenshot 2022-10-25 at 12 25 47

IMO it would be nice if it would be formatted into multiple lines if the string exceeds a certain width to maintain readability

https://github.com/flowerpowerdao/punks-nft-canister/pull/32/commits/521759d663068a907fdd95756e9ce823c4b7fe46#diff-303c0b742b59bc66b0e9f6e381809d383386ab3b0ba9cda25a74f1405fc411edL195-L196

rvanasa commented 2 years ago

Absolutely. I'll look into this for you as soon as I get a chance.

In the meantime, a // prettier-ignore comment will give you some extra control over the formatting.