tt.vue中使用video-player组件
用到的目录如下:
pages.json
{
"path": "pages/Tabbar/tt/tt",
"style": {
"navigationBarTitleText": "",
"enablePullDownRefresh": false,
// 使用自定义组件
"usingComponents": {
"video-player-dy": "/ttcomponents/videoPlayer/index"
}
}
}
tt.vue
<video-player-dy v-if="isShow" :albumId="albumId" :episodeId="episodeId"
style="width: 200px;height: 200px;"></video-player-dy>
index.json
{
"component": true,
"usingComponents": {
"video-player":"ext://industry/video-player"
}
}
index.ttml
<video-player bind:error="onError" album-id="{{albumId}}" episode-id="{{episodeId}}" cloud-type="{{1}}" version="1" />
index.js
Component({
methods: {
},
});