Search code examples
visual-studio-codeprettier

Prettier spacing


I'm starting to using VSC and looking for a good formatter for js, jsx, css, html.. etc

Tried several auto-indent extensions for VSC and for now settled with the Prettier, so I have few questions:

How to disable spacing:

  1. on arrow functions to const a=()=>{}; instead const a = () => {};
  2. on } else { to clear one: }else{
  3. on if (), for ()
  4. in function arguments (not important)

...I really hate this useless spacing

plus:

  1. How to refresh file in VSC? (exit without saving + open again - with one button (is it 'revert file', probably..))
  2. How to disable (or setup) amount empty lines between blocks onFormatPrettier (1 by default)
  3. (for devs) Why are there so few settings(for me :) ) in the extension?

Thanks


Solution

  • Modification only

    Official answer and "solution"