从内部理解第一行 angular v2.0.0.0-alpha.22.ts(列表与数组)
Understanding the first Line from inside angular v2.0.0.0-alpha.22.ts (Lists vs Arrays)
我现在有一些空闲时间,决定看看 Angular 2 Quickstart
line 11
上的 typings/angular2/angular2.d.ts
文件内部:
interface List<T> extends Array<T> {}
我知道这一行有很多内容:
问题:
What is the difference between List and Array through the lens of javascript/ts?
When should I consider using Lists vs Arrays?
What would be an example of using a List vs an Array?
What is the difference between List and Array through the lens of javascript/ts?
None。
When should I consider using Lists vs Arrays?
使用数组。 List 只是一个可选的命名(实际上是一个别名)。
What would be an example of using a List vs an Array?
一般只用Array
.
我现在有一些空闲时间,决定看看 Angular 2 Quickstart
line 11
上的 typings/angular2/angular2.d.ts
文件内部:
interface List<T> extends Array<T> {}
我知道这一行有很多内容:
问题:
What is the difference between List and Array through the lens of javascript/ts?
When should I consider using Lists vs Arrays?
What would be an example of using a List vs an Array?
What is the difference between List and Array through the lens of javascript/ts?
None。
When should I consider using Lists vs Arrays?
使用数组。 List 只是一个可选的命名(实际上是一个别名)。
What would be an example of using a List vs an Array?
一般只用Array
.