泛型类型TypeScript 中,类型(interface, type)是可以声明成泛型的,这很常见。 interface Props<T> {
content: T;
}这表明
type StringProps = Props<string>;
let props: StringProps;
props = {
// |
相关文章:
泛型类型TypeScript 中,类型(interface, type)是可以声明成泛型的,这很常见。 interface Props<T> {
content: T;
}这表明
type StringProps = Props<string>;
let props: StringProps;
props = {
// |
相关文章: