astring icon indicating copy to clipboard operation
astring copied to clipboard

Single, double and auto quotes

Open emilos opened this issue 5 years ago • 1 comments

Motivation

As a developer, I'd like to use astring as a part of a code transformation toolchain and pick the type of quotes that are going to be rendered.

Expected behavior

It should be possible to pass a quotes option that accepts: single | double | auto that change the quotes in the output.

Actual behavior

The library preserves existing quotes automatically (which is how auto mode works).

Implementation notes

The change would be non-breaking as the flag could be set to auto by default.

emilos avatar Dec 19 '19 13:12 emilos

Custom formatting is low-priority and won't be tackled soon. However, a pull request is welcome.

davidbonnet avatar Jan 12 '20 19:01 davidbonnet