Beautify on save in VS code?

前端 未结 2 587
小蘑菇
小蘑菇 2021-02-07 08:01

I just installed a beautify extension for vs code

I want to have my code beautified whenever I save a file, but can\'t figure out how to configure it that way.

I

2条回答
  •  谎友^
    谎友^ (楼主)
    2021-02-07 08:59

    For Windows click on 'File' -> Preferences -> Settings. Then search for editor.formatOnSave, and put "true" instead of "false"

    For Mac click on 'Code' (top left of screen, to the left of 'File', 'Edit', and 'View') -> Preferences -> Settings -> enter the term 'editor.formatOnSave' in the search settings box at the top of the page. Click on the tick to mark it as true.

提交回复
热议问题