开发者

How to @suppress multiple warnings with Closure Compiler?

It's possible to suppress warnings on a per-file basis with Google's Closure Compiler via the @suppress annotation. However, it doesn't seem to be possible to suppress multiple warnings at the same time--for example the globalThis and checkVars warnings. 开发者_开发知识库I tried both

/**
 * @fileoverview
 * @suppress {globalThis checkVars}
 */

and

/**
 * @fileoverview
 * @suppress {globalThis,checkVars}
 */

but both result in the @suppress annotation being ignored. Multiple @suppress lines also do not work.


Separate the types with the pipe character (eg: '|').

/**
 * @fileoverview
 * @suppress {globalThis|checkVars}
 */
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜