Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Turn all boolean options into enums? #195

Open
lassik opened this issue Oct 7, 2018 · 2 comments
Open

Turn all boolean options into enums? #195

lassik opened this issue Oct 7, 2018 · 2 comments

Comments

@lassik
Copy link
Contributor

lassik commented Oct 7, 2018

I've been thinking about this for a while. Quoting from here:

Language version may become a first class feature for Unibeautify. Prettier's Trailing Commas option has an es5 option: https://prettier.io/docs/en/options.html#trailing-commas
Whereas Unibeautify's End With Comma option is boolean (only true or false): https://unibeautify.com/docs/option-end-with-comma.html?language=javascript

Should we have boolean beautifier options at all? It seems that for many options that initially seem like an 'on' or 'off' kind of thing, people will later realize that there is a third alternative. Having everything be an enum from the start would enable us to add new alternatives more gracefully. many clang-format options seem to be specified with this in mind in.

@Glavin001
Copy link
Member

I have been thinking the exact same thing!

A lot of the existing Unibeautify options were copied from Atom-Beautify. I definitely think they need improving, both in terms of the possible option values supported and also if they should be renamed ( #182 ).

@Glavin001
Copy link
Member

@stevenzeck thoughts?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants