Skip to content

Commit

Permalink
fix(xgplayer/proxy.js, README.md): support crossorigin textTrack, rew…
Browse files Browse the repository at this point in the history
…rite the git clone method for s
  • Loading branch information
zhangxin92 committed Aug 3, 2018
1 parent eab3bad commit 21aa3cc
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 11 deletions.
7 changes: 3 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,18 +78,17 @@ xgplayer supports mobile terminal, but android device brand and system are numer

### Dev

For debugging, we provide the example video resource which size is large in github. You can clone the whole git repository which includes codes and example videos with 'git clone --recurse-submodules -j8'. With 'git clone' you will pull only codes of xgplayer and its plugins.

```
$ git clone git@github.com:bytedance/xgplayer.git
$ git clone --recurse-submodules -j8 git@github.com:bytedance/xgplayer.git # OR git clone git@github.com:bytedance/xgplayer.git
$ cd xgplayer
$ npm install
$ npm run dev
```

please visit [http://localhost:9090/examples/index.html](http://localhost:9090/examples/index.html)

### Note

you can sparse checout the source code without examples that include large video files. [how to sparse checkout git project](https://gist.github.com/sumardi/5559896)

### License

Expand Down
7 changes: 3 additions & 4 deletions README.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,18 +80,17 @@ let player = new Player({

### Dev

为了方便开发者调试,我们提供了示例视频资源。示例文件较大,可使用 git clone --recurse-submodules -j8 命令完整拉取源码和示例文件;如果你只对源码感兴趣可以使用 git clone 命令仅拉取源码部分。

```
$ git clone git@github.com:bytedance/xgplayer.git
$ git clone --recurse-submodules -j8 git@github.com:bytedance/xgplayer.git # 或者:git clone git@github.com:bytedance/xgplayer.git
$ cd xgplayer
$ npm install
$ npm run dev
```

访问 [http://localhost:9090/examples/index.html](http://localhost:9090/examples/index.html)

### Note

如果你只对源码感兴趣可以使用 Git 的稀疏检出功能忽略 examples 目录,里面有比较大的视频文件。[如何使用 Git 的sparse checkout](https://gist.github.com/sumardi/5559896)

### License

Expand Down
5 changes: 4 additions & 1 deletion packages/xgplayer/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,15 +81,18 @@ xgplayer supports mobile terminal, but android device brand and system are numer

### Dev

For debugging, we provide the example video resource which size is large in github. You can clone the whole git repository which includes codes and example videos with 'git clone --recurse-submodules -j8'. With 'git clone' you will pull only codes of xgplayer and its plugins.

```
$ git clone git@github.com:bytedance/xgplayer.git
$ git clone --recurse-submodules -j8 git@github.com:bytedance/xgplayer.git # OR git clone git@github.com:bytedance/xgplayer.git
$ cd xgplayer
$ npm install
$ npm run dev
```

please visit [http://localhost:9090/examples/index.html](http://localhost:9090/examples/index.html)


### License

[MIT](http://opensource.org/licenses/MIT)
2 changes: 1 addition & 1 deletion packages/xgplayer/browser/index.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion packages/xgplayer/dist/index.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions packages/xgplayer/src/proxy.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ class Proxy {
return true
}
})
videoConfig.crossorigin = 'anomymous'
}
if (options.textTrackStyle) {
let style = document.createElement('style')
Expand Down

0 comments on commit 21aa3cc

Please sign in to comment.