-
创建时间
20年1月19日
-
最后回复
20年1月22日
-
6
回复
-
1.4K
浏览
-
2
用户
我重新在ionic 4下尝试官方文档,这回把var AV =....换成import * as AV from 'leancloud-storage';这样就能通过编译了。但是同样办法在ionic 3下就会报错,而我的代码都是ionic 3写的。报错信息这回和leancloud有关,下面是VS code提示代码。
[app-scripts] [07:48:55] typescript: node_modules/leancloud-realtime/realtime.d.ts, line: 552
[app-scripts] ';' expected.
[app-scripts] L552: declare type EventContext = K extends keyof OptionalContext
[app-scripts] L553: ? OptionalContext[K]
[app-scripts] [07:48:55] typescript: node_modules/leancloud-realtime/realtime.d.ts, line: 552
[app-scripts] ';' expected.
[app-scripts] L552: declare type EventContext = K extends keyof OptionalContext
[app-scripts] L553: ? OptionalContext[K]
[app-scripts] [07:48:55] typescript: node_modules/leancloud-realtime/realtime.d.ts, line: 93
[app-scripts] A rest parameter must be of an array type.
[app-scripts] L92: listener: (payload?: ClientEvent[K]) => any,
[app-scripts] L93: ...context: EventContext
[app-scripts] L94: ): this;
[app-scripts] A rest parameter must be of an array type.
[app-scripts] L99: conversaion?: ConversationBase,
[app-scripts] L100: ...context: EventContext
[app-scripts] L101: ) => any
[app-scripts] A rest parameter must be of an array type.
[app-scripts] L104: event: K,
[app-scripts] L105: listener: (payload?: ClientEvent[K], ...context: EventContext) => any
[app-scripts] L106: ): this;
[app-scripts] A rest parameter must be of an array type.
[app-scripts] L111: conversaion?: ConversationBase,
[app-scripts] L112: ...context: EventContext
[app-scripts] L113: ) => any
[app-scripts] A rest parameter must be of an array type.
[app-scripts] L359: listener: (payload?: T[K]) => any,
[app-scripts] L360: ...context: EventContext
[app-scripts] L361: ): this;
[app-scripts] A rest parameter must be of an array type.
[app-scripts] L365: listener: (payload?: T[K]) => any,
[app-scripts] L366: ...context: EventContext
[app-scripts] L367: ): this;
推荐主题
主题 | 分类 | 回复 | 浏览 | 活动 |
---|---|---|---|---|
推送api为什么一直变来变去 | SDK / API | 1 | 703 | 15-09-2 |
Web hosting访问问题 | SDK / API | 3 | 866 | 15-09-3 |
短信模版里可以用简链吗? | SDK / API | 1 | 2.6K | 16-05-16 |
用loginwith尝试登陆报Batch requests error | SDK / API | 2 | 732 | 16-01-21 |
CQL怎么使用op函数删除对象里的属性? | SDK / API | 1 | 929 | 18-01-5 |