SevenOutman / vue-aplayer

:cake: Easy-to-use music player for Vue 2.x
https://vue-aplayer.js.org
MIT License
1.33k stars 200 forks source link

引用本地音乐的时候控制台显示[Vue-APlayer] NotSupportedError: The element has no supported sources. #219

Open Yuban32 opened 4 years ago

Yuban32 commented 4 years ago

这是Vue模板中的代码,我用本地的资源就会提示NotSupportedError,请问这是什么原因? 模板和音乐资源不在同一个目录里

Yuban32 commented 4 years ago

害 没事了 加require就行了XD src:require("../assets/music/SnowSnowSnow.mp3")

bestras023 commented 2 years ago

Hi @Mashiro10032 if add require, can the local music file be played? Please let me know. Thanks.

Yuban32 commented 2 years ago

Hi @Mashiro10032 if add require, can the local music file be played? Please let me know. Thanks.

yes, need to add require

bestras023 commented 2 years ago

Thanks. I'm trying to play in-memory blob audio file now. Would you recommend the package name?

Yuban32 commented 2 years ago

Thanks. I'm trying to play in-memory blob audio file now. Would you recommend the package name?

sorry bro, I haven't used blob. XD

bestras023 commented 2 years ago

what did you use, then?

Yuban32 commented 2 years ago

I play MP3 files