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

请问如何安装没有hls.js的版本 #36

Closed
lixajh opened this issue May 1, 2018 · 8 comments
Closed

请问如何安装没有hls.js的版本 #36

lixajh opened this issue May 1, 2018 · 8 comments

Comments

@lixajh
Copy link

lixajh commented May 1, 2018

因为hls.js体积很大,请问是否支持安装没有hls.js的版本?

@SevenOutman
Copy link
Owner

@lixajh 请说的具体一点,看不懂你想问什么

@lixajh lixajh changed the title 请问如何安装没有hls.js 请问如何安装没有hls.js的版本 May 1, 2018
@lixajh
Copy link
Author

lixajh commented May 1, 2018

不好意思,不小心按到回车就发出去了。手动允悲。

@SevenOutman
Copy link
Owner

SevenOutman commented May 1, 2018

@lixajh Vue-APlayer 并不会自动安装 hls.js。如果你需要支持 m3u8,才需要手动安装 hls.js。
你可以:

  • 文档中了解这一点。
  • package.json 中看到 hls.js 是 optionalDependency 而不是 dependency

如果这解决了你的问题,你随时可以关闭这个 issue。

@lixajh
Copy link
Author

lixajh commented May 2, 2018

我是用npm安装Vue-Aplayer,之前没有安装过hls.js。然而打包项目后webpack report显示确实有hls.js。我尝试了uninstall hls.js,没有作用。

@SevenOutman
Copy link
Owner

@lixajh 请问你安装的 Vue-APlayer 是什么版本?

@lixajh
Copy link
Author

lixajh commented May 2, 2018

"vue-aplayer": "^1.5.0",

@SevenOutman
Copy link
Owner

@lixajh 看起来的确是这样。

你可以使用 --no-optional 标记来避免安装 optional dependencies。

npm install --save vue-aplayer --no-optional

@SevenOutman
Copy link
Owner

@lixajhvue-aplayer@1.5.1 中,hls.jsoptionalDependencies 中被移除。

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

No branches or pull requests

2 participants