code 类型 英文描述 中文描述 1002 错误 Unterminated string literal. 未终止的字符串文本。 1003 错误 Identifier expected. 应为标识符。 1005 错误 '{0}' expected. 应为“{0}”。 1006 错误 A file cannot have a reference to itself. 文件不能引用自身。 1009 错误 Trailing comma not allowed. 不允许使用尾随逗号。 1010 错误 '*/' expected. 应为 "*/"。 1012 错误 Unexpected token. 意外的标记。 1014 错误 A rest parameter must be last in a parameter list. rest 参数必须是参数列表中的最后一个参数。 1015 错误 Parameter cannot have question mark and initializer. 参数不能包含问号和初始化表达式。 1016 错误 A required parameter cannot follow an optional parameter. 必选参数不能位于可选参数后。 1017 错误 An index signature cannot have a rest parameter. 索引签名不能包含 rest 参数。 1018 错误 An index signature parameter cannot have an accessibility modifier. 索引签名参数不能具有可访问性修饰符。 1019 错误 An index signature parameter cannot have a question mark. 索引签名参数不能包含问号。 1020 错误 An index signature parameter cannot have an initializer. 索引签名参数不能具有初始化表达式。 1021 错误 An index signature must have a type annotation. 索引签名必须具有类型批注。 1022 错误 An
TypeScript报错信息表(备注)
最新推荐文章于 2024-02-03 12:00:17 发布