- npm i @easydarwin/easyplayer -S
- 将node_modules/@easydarwin/easyplayer/dist/element/EasyPlayer-element.min.js复制到静态文件public中
- 在index.html中引入EasyPlayer-element.min.js
- 在页面使用:easy-player
<easy-player
video-url="xxx.m3u8"
live="true"
show-custom-button="false"
isH265="true"
fluent
ref="playerRef"
class="player"
></easy-player>
注意这样写不行:EasyPlayer
<EasyPlayer
video-url="xxx.m3u8"
live="true"
show-custom-button="false"
isH265="true"
fluent
ref="playerRef"
class="player"
></EasyPlayer>