typescript 与 cube-ui create-api结合使用

来源:3-3 header-detail & star 组件

yanchang

2019-02-11

Argument of type ‘VueConstructor’ is not assignable to parameter of type ‘CubeUIComponent’.
Type ‘VueConstructor’ is missing the following properties from type ‘CubeUIComponent’: $el, $options, $parent, $root, and 32 more. [2345]
请问这个问题该如何解决

写回答

2回答

yanchang

提问者

2019-02-13

1234

0
0

ustbhuangyi

2019-02-12

贴一下相关代码我看看

0
2
ustbhuangyi
回复
yanchang
你定义 HeaderDetail 这个组件的时候需要去 extends CubeUIComponent,这个 CubeUIComponent 的定义在https://github.com/didi/cube-ui/blob/dev/types/component.d.ts
2019-02-13
共2条回复

Vue.js2.5+cube-ui重构饿了么App(经典再升级)

掌握Vue1.0到2.0再到2.5最全版本应用与迭代,打造极致流畅的WebApp

9868 学习 · 4162 问题

查看课程