test(types): assert props are readonly
This commit is contained in:
parent
f2cdc82be3
commit
a5f962ab8e
@ -50,6 +50,9 @@ describe('with object props', () => {
|
|||||||
expectType<ExpectedProps['ccc']>(props.ccc)
|
expectType<ExpectedProps['ccc']>(props.ccc)
|
||||||
expectType<ExpectedProps['ddd']>(props.ddd)
|
expectType<ExpectedProps['ddd']>(props.ddd)
|
||||||
|
|
||||||
|
// props should be readonly
|
||||||
|
expectError((props.a = 1))
|
||||||
|
|
||||||
// setup context
|
// setup context
|
||||||
return {
|
return {
|
||||||
c: ref(1),
|
c: ref(1),
|
||||||
|
Loading…
Reference in New Issue
Block a user