@4rk/video-lib 中文文档教程
VideoLib
HTML 视频播放的辅助方法。
该库可帮助您解决在实现自定义 HTML5 视频播放器时出现的问题。 特别是,它有辅助方法:
- Use movingimage with HLS as source, with fallback for non-HLS-compatible browsers
- Apply custom CSS style to subtitles
- Emulating
object-fit: cover;
with Internet Explorer support - Waiting for a video to become ready
请查看每个方法的 JSDoc 以获取更多信息。
Tricks
- Some browsers do not accept
<track kind="subtitles">
to bemode="hidden"
. Usekind="metadata"
instead.
Creating a release
需要完成某些步骤才能创建新版本:
- Decide on a semver version number
- Start a new release using
git flow release start [version number]
- Update the
package.json
version - Run
yarn run release
- Commit changes:
git commit -a -m "Prepare release [version number]"
- Finish release using
git flow release finish
- Push all changes:
git push origin --all && git push origin --tags
License
请参阅 LICENSE
VideoLib
Helper methods for HTML video playback.
This library helps you on problems occuring when implementing custom HTML5 video players. In particular, it has helper methods to:
- Use movingimage with HLS as source, with fallback for non-HLS-compatible browsers
- Apply custom CSS style to subtitles
- Emulating
object-fit: cover;
with Internet Explorer support - Waiting for a video to become ready
Please take a look at the JSDoc of each method for further information.
Tricks
- Some browsers do not accept
<track kind="subtitles">
to bemode="hidden"
. Usekind="metadata"
instead.
Creating a release
Certain steps need to be done in order to create a new release:
- Decide on a semver version number
- Start a new release using
git flow release start [version number]
- Update the
package.json
version - Run
yarn run release
- Commit changes:
git commit -a -m "Prepare release [version number]"
- Finish release using
git flow release finish
- Push all changes:
git push origin --all && git push origin --tags
License
See LICENSE