1.取消縮進檢查、編輯器配置:
File > Settings >
Editor > Code Style >
取消Indents Detection和EditorConfig勾選

2.設定代碼縮進設定
File > Settings >
 Editor > Code Style >
  HTML、JavaScript、TypeScript、CSS 的 Tab size、Indent、Continuation 設置為2

3.script標簽和style標簽修改後首行(換行)不縮進
File > Settings > Editor >
Code Style > HTML、JavaScript、TypeScript、CSS 的 Do not indent children of: >
點擊右邊的文件夾  >打開的小窗口中點擊+,將「script」、「style」標簽加進去。

4.設定函數名後括號的空格
File > Settings >
Editor > Code Style >
HTML、JavaScript、TypeScrip > Before Parentheses >
取消Function declaration parentheses、In function expression勾選

5.宣告物件的花括號前後各有一個空格
File > Settings >
Editor > Code Style >
HTML、JavaScript、TypeScrip > Within  > 選擇 Object literal braces 勾選

 

arrow
arrow
    文章標籤
    WebStorm webformat storm format
    全站熱搜

    bingzhichen 發表在 痞客邦 留言(0) 人氣()