Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

想问下大佬如果默认一个src,有某权限,替换另外一个src的对象,是在哪个事件里面替换呢,loadstart会无限循环 #197

Open
shilianmalaxiangguo opened this issue Apr 9, 2020 · 1 comment

Comments

@shilianmalaxiangguo
Copy link

let _audio_buy_info = 'xxxxx'
if (_audio_buy_info) {
let _pre_info = _this.audioInfo
_pre_info.src = _audio_buy_info.src
_this.audioInfo = Object.assign({}, _pre_info)
}

audioInfo是music的对象,但是在loadstart事件里面会无限循环,canplay也是

@shilianmalaxiangguo
Copy link
Author

目前只能在mounted 或者watch created 里面替换,想的是 video标签也有的ready事件,那么audio应该也有类似的吧

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant