mirror of
https://github.com/videojs/video.js.git
synced 2025-02-02 11:34:50 +02:00
docs: update note about accessing tech (#7141)
This commit is contained in:
parent
b2336aacc9
commit
7d46f44df9
@ -27,7 +27,7 @@ This document outlines many considerations for using Video.js for advanced playe
|
||||
After an instance has been created it can be accessed globally in two ways:
|
||||
|
||||
1. By calling `videojs('example_video_id');`
|
||||
1. By using it directly via `videojs.players.example_video_id;`
|
||||
1. By using it directly via `videojs.players.example_video_id;`
|
||||
|
||||
## Removing Players
|
||||
|
||||
@ -353,23 +353,20 @@ console.log(myPlayer.poster());
|
||||
|
||||
## Accessing the Tech on the player
|
||||
|
||||
The tech on the player can only be accesed by pasing `{IWillNotUseThisInPlugins: true}` into the `tech()`
|
||||
function on the player.
|
||||
The tech on the player can be accessed via `tech()`. Passing any argument will silence the warning that is logged.
|
||||
|
||||
```js
|
||||
var myPlayer = videojs('some-player-id');
|
||||
|
||||
myPlayer.src({type: 'video/mp4', src: 'http://www.example.com/path/to/video.mp4'});
|
||||
myPlayer.ready(function() {
|
||||
// tech() will error with no argument
|
||||
var tech = myPlayer.tech({IWillNotUseThisInPlugins: true});
|
||||
// tech() will log warning without any argument
|
||||
var tech = myPlayer.tech(false);
|
||||
});
|
||||
```
|
||||
|
||||
## Using Video.js with...
|
||||
|
||||
Coming soon...
|
||||
|
||||
### jQuery
|
||||
|
||||
### React
|
||||
|
Loading…
x
Reference in New Issue
Block a user