标签: typescript
在此代码上,打字稿显示错误:A rest element type must be an array type
A rest element type must be an array type
type B<X extends any[]> = [...X];
但是,此代码有效
type A = any[]; type B = [...A];
为什么?