【发布时间】:2017-01-16 17:15:08
【问题描述】:
我是 TypeScript 新手,如果我犯了错误,请多多包涵。
根据在线 TypeScript 指南this,以下 TypeSript 是有效的:
function foo(x, y, z) { }
var args = [0, 1, 2];
foo(...args);
相反,当我运行 tsc *.ts --watch --target ES6 来编译我的 TypeScript 时,我得到了 error TS2346: Supplied parameters do not match any signature of call target.
这不应该很好吗?这是一项相当基本的任务,那我做错了什么?
【问题讨论】:
-
你使用的是什么版本的
tsc? -
这是一个已知的 Typescript 问题:github.com/Microsoft/TypeScript/issues/4130
标签: typescript tsc