Use prettier to unify coding style
kevinsandow opened this issue · 2 comments
kevinsandow commented
Before introducing other linters like eslint
we should get the formatting in order.
As reasoning I'd like to quote prettier:
What is Prettier?
- An opinionated code formatter
- Has few options
Why?
- No need to discuss style in code review
- Saves you time and energy
For the options part I'd like it if @kaansoral decides the way his projects should look like:
- Tab WIdth seems to be 2 - at least where spaces were used instead of tabs (already prettier default)
- Tabs - the code currently mostly uses tabs, this could be "semi" enforced with this option, but it's neither default nor would I suggest using it
- Semicolons - the current code uses them, they are the prettier default, no fuss
- Single Quotes - there are is a 20:1 ration of double quotes to single quote, I suggest using double quotes here (majority & prettier default)
- Bracket Spacing: true is default and increases readability - though it has not been used currently, so it could be disabled
thmsndk commented
Relevant talk on discord https://discord.com/channels/238332476743745536/1163453037126357074/1165569875083808839 where telokis outlines a formatting & linting plan.
Telokis commented
I think we can close this issue, the work has started in #54
The conversation can be found in the discord thread: https://discord.com/channels/238332476743745536/1163453037126357074
If you think I shouldn't close this, let me know and we'll reopen it.