【发布时间】:2013-04-11 03:48:40
【问题描述】:
我在一个特定的 javascript 文件中得到以下信息
Line 23, E:0233: Optional parameter name category must be prefixed with opt_.
Line 649, E:0233: Optional parameter name animate must be prefixed with opt_.
Line 697, E:0233: Optional parameter name aggregate must be prefixed with opt_.
Line 763, E:0233: Optional parameter name animate must be prefixed with opt_.
Line 796, E:0233: Optional parameter name animate must be prefixed with opt_.
第一个代码是:
/** @constructor
*
* @param {Object} data an entity or item.
* @param {Object} parent a viewObj, or at the root level, a viewstate.
* @param {Array.<number>} position an (x$, y$) pair.
* @param {string=} category The category to give the item. This forms an
* inconsistent mess around where category is stored.
*/
function ViewObj(data, parent, position, category) {
错误代码的意义何在? “类别”不是可选的!
【问题讨论】:
标签: javascript gjslint