構文の末尾にセミコロン(;)がありません。
エラー例
if (!value) {
return false
}
解決方法
-
構文の末尾にセミコロン(;)を追加します。
if (!value) { return false; }
-
tslint.jsonの "semicolon" 設定を削除するか、false を指定して無効にします。
セミコロンを省略すると意図しない動作をする恐れがあるため、この方法は推奨しません。
tslint.json
{ "rules": { "semicolon": [ false, "always" ] } }
検証環境
- typescript 2.6.2
- tslint 5.9.1
- Microsoft Windows 7 Professional Service Pack 1 (Microsoft Windows NT 6.1 (7601))