a***@163.com
a***@163.com
  • 发布:2023-07-22 15:33
  • 更新:2023-07-22 15:33
  • 阅读:274

升级编译器3.8.7,编译的时候提示错误

分类:uni-app

ERROR Failed to compile with 11 errors 15:26:38

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts
39:12 'string' only refers to a type, but is being used as a value here.
37 | https://github.com/frenic/csstype#what-should-i-do-when-i-get-type-errors
38 |
/

39 | [v: --${string}]: string | number | undefined
| ^
40 | }
41 |
42 | type Booleanish = boolean | 'true' | 'false'

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts
39:23 'string' only refers to a type, but is being used as a value here.
37 | https://github.com/frenic/csstype#what-should-i-do-when-i-get-type-errors
38 |
/

39 | [v: --${string}]: string | number | undefined
| ^
40 | }
41 |
42 | type Booleanish = boolean | 'true' | 'false'

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts
39:32 'number' only refers to a type, but is being used as a value here.
37 | https://github.com/frenic/csstype#what-should-i-do-when-i-get-type-errors
38 |
/

39 | [v: --${string}]: string | number | undefined
| ^
40 | }
41 |
42 | type Booleanish = boolean | 'true' | 'false'

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts
39:41 Object is possibly 'undefined'.
37 | https://github.com/frenic/csstype#what-should-i-do-when-i-get-type-errors
38 |
/

39 | [v: --${string}]: string | number | undefined
| ^
40 | }
41 |
42 | type Booleanish = boolean | 'true' | 'false'

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts
51:6 Type alias 'InferPropType' circularly references itself.
49 | : Exclude<T, Function>
50 |

51 | type InferPropType<T> = [T] extends [null]
| ^
52 | ? any // null & true would fail to infer
53 | : [T] extends [{ type: null | true }]
54 | ? any // As TS issue https://github.com/Microsoft/TypeScript/issues/14829 // somehow ObjectConstructor when inferred from { (): T } becomes any // BooleanConstructor when inferred from PropConstructor(with PropMethod) becomes Boolean

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts
63:14 Type 'InferPropType' is not generic.
61 | : [T] extends [(infer U)[] | { type: (infer U)[] }]
62 | ? U extends DateConstructor

63 | ? Date | InferPropType<U>
| ^
64 | : InferPropType<U>
65 | : [T] extends [Prop<infer V, infer D>]
66 | ? unknown extends V

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts
64:7 Type 'InferPropType' is not generic.
62 | ? U extends DateConstructor
63 | ? Date | InferPropType<U>

64 | : InferPropType<U>
| ^
65 | : [T] extends [Prop<infer V, infer D>]
66 | ? unknown extends V
67 | ? IfAny<V, V, D>

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts
73:42 Type 'InferPropType' is not generic.
71 | export type ExtractPropTypes<O> = {
72 | // use keyof Pick<O, RequiredKeys<O>> instead of RequiredKeys<O> to support IDE features

73 | [K in keyof Pick<O, RequiredKeys<O>>]: InferPropType<O[K]>
| ^
74 | } & {
75 | // use keyof Pick<O, OptionalKeys<O>> instead of OptionalKeys<O> to support IDE features
76 | [K in keyof Pick<O, OptionalKeys<O>>]?: InferPropType<O[K]>

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts
76:43 Type 'InferPropType' is not generic.
74 | } & {
75 | // use keyof Pick<O, OptionalKeys<O>> instead of OptionalKeys<O> to support IDE features

76 | [K in keyof Pick<O, OptionalKeys<O>>]?: InferPropType<O[K]>
| ^
77 | }
78 |
79 | type DefaultKeys<T> = {

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts
98:45 Type 'InferPropType' is not generic.
96 | export type ExtractDefaultPropTypes<O> = O extends object
97 | ? // use keyof Pick<O, DefaultKeys<O>> instead of DefaultKeys<O> to support IDE features

98 | { [K in keyof Pick<O, DefaultKeys<O>>]: InferPropType<O[K]> }
| ^
99 | : {}
100 |

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-generated.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-generated.d.ts
394:115 A rest element type must be an array type.
392 | / Excluded from this release type: VNodeDirective /
393 |

394 | export declare function watch<T extends MultiWatchSources, Immediate extends Readonly<boolean> = false>(sources: [...T], cb: WatchCallback<MapSources<T, false>, MapSources<T, Immediate>>, options?: WatchOptions<Immediate>): WatchStopHandle;
| ^
395 |
396 | export declare function watch<T extends Readonly<MultiWatchSources>, Immediate extends Readonly<boolean> = false>(source: T, cb: WatchCallback<MapSources<T, false>, MapSources<T, Immediate>>, options?: WatchOptions<Immediate>): WatchStopHandle;
397 |

⠙ 开始编译当前项目至 app-plus 平台...

ERROR Failed to compile with 11 errors 15:26:38

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts
39:12 'string' only refers to a type, but is being used as a value here.
37 | https://github.com/frenic/csstype#what-should-i-do-when-i-get-type-errors
38 |
/

39 | [v: --${string}]: string | number | undefined
| ^
40 | }
41 |
42 | type Booleanish = boolean | 'true' | 'false'

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts
39:23 'string' only refers to a type, but is being used as a value here.
37 | https://github.com/frenic/csstype#what-should-i-do-when-i-get-type-errors
38 |
/

39 | [v: --${string}]: string | number | undefined
| ^
40 | }
41 |
42 | type Booleanish = boolean | 'true' | 'false'

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts
39:32 'number' only refers to a type, but is being used as a value here.
37 | https://github.com/frenic/csstype#what-should-i-do-when-i-get-type-errors
38 |
/

39 | [v: --${string}]: string | number | undefined
| ^
40 | }
41 |
42 | type Booleanish = boolean | 'true' | 'false'

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/jsx.d.ts
39:41 Object is possibly 'undefined'.
37 | https://github.com/frenic/csstype#what-should-i-do-when-i-get-type-errors
38 |
/

39 | [v: --${string}]: string | number | undefined
| ^
40 | }
41 |
42 | type Booleanish = boolean | 'true' | 'false'

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts
51:6 Type alias 'InferPropType' circularly references itself.
49 | : Exclude<T, Function>
50 |

51 | type InferPropType<T> = [T] extends [null]
| ^
52 | ? any // null & true would fail to infer
53 | : [T] extends [{ type: null | true }]
54 | ? any // As TS issue https://github.com/Microsoft/TypeScript/issues/14829 // somehow ObjectConstructor when inferred from { (): T } becomes any // BooleanConstructor when inferred from PropConstructor(with PropMethod) becomes Boolean

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts
63:14 Type 'InferPropType' is not generic.
61 | : [T] extends [(infer U)[] | { type: (infer U)[] }]
62 | ? U extends DateConstructor

63 | ? Date | InferPropType<U>
| ^
64 | : InferPropType<U>
65 | : [T] extends [Prop<infer V, infer D>]
66 | ? unknown extends V

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts
64:7 Type 'InferPropType' is not generic.
62 | ? U extends DateConstructor
63 | ? Date | InferPropType<U>

64 | : InferPropType<U>
| ^
65 | : [T] extends [Prop<infer V, infer D>]
66 | ? unknown extends V
67 | ? IfAny<V, V, D>

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts
73:42 Type 'InferPropType' is not generic.
71 | export type ExtractPropTypes<O> = {
72 | // use keyof Pick<O, RequiredKeys<O>> instead of RequiredKeys<O> to support IDE features

73 | [K in keyof Pick<O, RequiredKeys<O>>]: InferPropType<O[K]>
| ^
74 | } & {
75 | // use keyof Pick<O, OptionalKeys<O>> instead of OptionalKeys<O> to support IDE features
76 | [K in keyof Pick<O, OptionalKeys<O>>]?: InferPropType<O[K]>

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts
76:43 Type 'InferPropType' is not generic.
74 | } & {
75 | // use keyof Pick<O, OptionalKeys<O>> instead of OptionalKeys<O> to support IDE features

76 | [K in keyof Pick<O, OptionalKeys<O>>]?: InferPropType<O[K]>
| ^
77 | }
78 |
79 | type DefaultKeys<T> = {

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-component-props.d.ts
98:45 Type 'InferPropType' is not generic.
96 | export type ExtractDefaultPropTypes<O> = O extends object
97 | ? // use keyof Pick<O, DefaultKeys<O>> instead of DefaultKeys<O> to support IDE features

98 | { [K in keyof Pick<O, DefaultKeys<O>>]: InferPropType<O[K]> }
| ^
99 | : {}
100 |

error in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-generated.d.ts

ERROR in /Users/chenhua/Documents/web项目/HBuilderProject/machine/node_modules/vue/types/v3-generated.d.ts
394:115 A rest element type must be an array type.
392 | / Excluded from this release type: VNodeDirective /
393 |

394 | export declare function watch<T extends MultiWatchSources, Immediate extends Readonly<boolean> = false>(sources: [...T], cb: WatchCallback<MapSources<T, false>, MapSources<T, Immediate>>, options?: WatchOptions<Immediate>): WatchStopHandle;
| ^
395 |
396 | export declare function watch<T extends Readonly<MultiWatchSources>, Immediate extends Readonly<boolean> = false>(source: T, cb: WatchCallback<MapSources<T, false>, MapSources<T, Immediate>>, options?: WatchOptions<Immediate>): WatchStopHandle;
397 |

DONE Build complete.
ERROR Build failed with errors.

2023-07-22 15:33 负责人:无 分享
已邀请:

要回复问题请先登录注册