TypeScript/tests/cases/compiler/mappedTypePartialNonHomomorphicBaseConstraint.ts
Wesley Wigham 58e847abb5
Add assignability rule relaxing the assignability of partial mapped types (#30112)
* Add assignability rule relaxing the assignability of partial mapped types

* Update comment
2019-03-08 14:01:27 -08:00

8 lines
173 B
TypeScript

export type Errors<D> = { readonly [K in keyof D | "base"]?: string[] };
class Model<D> {
getErrors(): Errors<D> {
return { base: ["some base error"] };
}
}