jslint4java

How to tell JSLint not to ask for { on single line if statements

泪湿孤枕 提交于 2019-11-28 07:05:03
问题 Right now I have the following code: if (c > last) break; And jslint complains with jslint:crud.js:69:19:Expected '{' and instead saw 'break'. There are several ways to overcome it: if (c > last) { break; } or if (c > last) { break; } But I'd like jslint not to complain when the if statement is on the same line. Is there some way to configure it? BTW: I'm working with sublime text and the sublime-jslint plugin, with the following configuration: { // Path to the jslint jar. // Leave blank to