Skip to content

docs: Update required typescript version #802

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 23, 2021

Conversation

anikeef
Copy link
Contributor

@anikeef anikeef commented Aug 23, 2021

This plugin relies on Typescript "Recursive Type Aliases" improvement, which was released with Typescript 3.7:
https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-7.html#more-recursive-type-aliases

If used with Typescript 3.5.1 (the version specified in docs), typescript would throw the following error:

251:14 Type alias 'DeepReadonly' circularly references itself.
    249 | declare type Primitive = string | number | boolean | bigint | symbol | undefined | null;
    250 | declare type Builtin = Primitive | Function | Date | Error | RegExp;
  > 251 | declare type DeepReadonly<T> = T extends Builtin ? T : T extends Map<infer K, infer V> ? ReadonlyMap<DeepReadonly<K>, DeepReadonly<V>> : T extends ReadonlyMap<infer K, infer V> ? ReadonlyMap<DeepReadonly<K>, DeepReadonly<V>> : T extends WeakMap<infer K, infer V> ? WeakMap<DeepReadonly<K>, DeepReadonly<V>> : T extends Set<infer U> ? ReadonlySet<DeepReadonly<U>> : T extends ReadonlySet<infer U> ? ReadonlySet<DeepReadonly<U>> : T extends WeakSet<infer U> ? WeakSet<DeepReadonly<U>> : T extends Promise<infer U> ? Promise<DeepReadonly<U>> : T extends {} ? {
        |              ^
    252 |     readonly [K in keyof T]: DeepReadonly<T[K]>;
    253 | } : Readonly<T>;
    254 | declare type UnwrapNestedRefs<T> = T extends Ref ? T : UnwrapRefSimple<T>;

This PR changes the required Typescript version in readme.

@antfu antfu merged commit cb60681 into vuejs:main Aug 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants