export default videojs; export type version = string; /** * The `videojs()` function doubles as the main function for users to create a * {@link Player} instance as well as the main library namespace. * * It can also be used as a getter for a pre-existing {@link Player} instance. * However, we _strongly_ recommend using `videojs.getPlayer()` for this * purpose because it avoids any potential for unintended initialization. * * Due to [limitations](https://github.com/jsdoc3/jsdoc/issues/955#issuecomment-313829149) * of our JSDoc template, we cannot properly document this as both a function * and a namespace, so its function signature is documented here. * * #### Arguments * ##### id * string|Element, **required** * * Video element or video element ID. * * ##### options * Object, optional * * Options object for providing settings. * See: [Options Guide](https://docs.videojs.com/tutorial-options.html). * * ##### ready * {@link Component~ReadyCallback}, optional * * A function to be called when the {@link Player} and {@link Tech} are ready. * * #### Return Value * * The `videojs()` function returns a {@link Player} instance. * * @namespace * * @borrows AudioTrack as AudioTrack * @borrows Component.getComponent as getComponent * @borrows module:events.on as on * @borrows module:events.one as one * @borrows module:events.off as off * @borrows module:events.trigger as trigger * @borrows EventTarget as EventTarget * @borrows module:middleware.use as use * @borrows Player.players as players * @borrows Plugin.registerPlugin as registerPlugin * @borrows Plugin.deregisterPlugin as deregisterPlugin * @borrows Plugin.getPlugins as getPlugins * @borrows Plugin.getPlugin as getPlugin * @borrows Plugin.getPluginVersion as getPluginVersion * @borrows Tech.getTech as getTech * @borrows Tech.registerTech as registerTech * @borrows TextTrack as TextTrack * @borrows VideoTrack as VideoTrack * * @param {string|Element} id * Video element or video element ID. * * @param {Object} [options] * Options object for providing settings. * See: [Options Guide](https://docs.videojs.com/tutorial-options.html). * * @param {PlayerReadyCallback} [ready] * A function to be called when the {@link Player} and {@link Tech} are * ready. * * @return {Player} * The `videojs()` function returns a {@link Player|Player} instance. */ declare function videojs(id: string | Element, options?: any, ready?: PlayerReadyCallback): Player; declare namespace videojs { export { hooks_ }; export { hooks }; export { hook }; export { hookOnce }; export { removeHook }; export { version as VERSION }; export let options: any; /** * Get an object with the currently created players, keyed by player ID * * @return {Object} * The created players */ export function getPlayers(): any; /** * Get a single player based on an ID or DOM element. * * This is useful if you want to check if an element or ID has an associated * Video.js player, but not create one if it doesn't. * * @param {string|Element} id * An HTML element - `