2016-09-27 28 views
0

今天更新了格式化刪除的空間PhpStorm 2016年2月1日PhpStorm 2016年2月1日左右打字稿結腸

突然我的格式在我的TS文件是不正確的,根據我的TSLint規則。

"typedef-whitespace": [ 
     true, 
     { 
     "call-signature": "nospace", 
     "index-signature": "nospace", 
     "parameter": "nospace", 
     "property-declaration": "nospace", 
     "variable-declaration": "nospace" 
     }, 
     { 
     "call-signature": "nospace", 
     "index-signature": "nospace", 
     "parameter": "nospace", 
     "property-declaration": "nospace", 
     "variable-declaration": "nospace" 
     } 
    ] 

enter image description here

Editor > Code Style > Typescript沒有例子也不排除一個類型的斷言後,除去空間。

enter image description here

回答

0

In Editor > Code Style > Typescript沒有例子也不排除一個類型的斷言後,除去空間。

嗯..我清楚地看到它在PhpStorm 2016年2月1日(的選擇,因爲在你的屏幕截圖指向箭頭,以消除那些2個空格)。我自己並不是一個TypeScript人(所有)..所以也許它不會影響你的代碼..但對我來說,它看起來是正確的選擇。

  1. Settings/Preferences | Editor | Code Style | TypeScript
  2. Spaces | Other | After type reference colon ':'

enter image description here

+0

OMG。我怎麼錯過那個。謝謝。 – Simon

相關問題