本篇文章小编给大家分享一下vue3+ts使用APlayer代码示例,文章代码介绍的很详细,小编觉得挺不错的,现在分享给大家供大家参考,有需要的小伙伴们可以来看看。
安装依赖
yarn add aplayer
代码
APlayer.Vue
player.ts
import axios from '@/utils/axios' export class player { static getSongSheet(server: string, type:String, id: String) { return axios.get(`https://api.i-meto.com/meting/api?server=${server}&type=${type}&id=${id}&r=${Math.random()}`); } }
效果图