atom-mprettier icon indicating copy to clipboard operation
atom-mprettier copied to clipboard

Use the range formatting feature of Prettier

Open j-f1 opened this issue 7 years ago • 0 comments

Currently, if some text is selected when formatting, that region is sliced out of the document and passed to Prettier. However, this can cause Prettier to fail if the selection isn’t a valid JS file by itself. Would it be possible to use the rangeStart and rangeEnd options to format the selection?

j-f1 avatar Aug 05 '18 15:08 j-f1