mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-02-28 19:52:53 +00:00
new definition file for hls.js (#16028)
* added hls.js definition * changed to new tslint format * fixing lint errors * changed definition structure based on PR comment
This commit is contained in:
parent
fa2480ba61
commit
58e2df31f6
11
types/hls.js/hls.js-tests.ts
Normal file
11
types/hls.js/hls.js-tests.ts
Normal file
@ -0,0 +1,11 @@
|
||||
import * as Hls from 'hls.js';
|
||||
|
||||
if (Hls.isSupported) {
|
||||
const video = <HTMLVideoElement> document.getElementById('video');
|
||||
const hls = new Hls();
|
||||
hls.loadSource('http://www.streambox.fr/playlists/test_001/stream.m3u8');
|
||||
hls.attachMedia(video);
|
||||
hls.on(Hls.Events.MANIFEST_PARSED, () => {
|
||||
video.play();
|
||||
});
|
||||
}
|
||||
1253
types/hls.js/index.d.ts
vendored
Normal file
1253
types/hls.js/index.d.ts
vendored
Normal file
File diff suppressed because it is too large
Load Diff
23
types/hls.js/tsconfig.json
Normal file
23
types/hls.js/tsconfig.json
Normal file
@ -0,0 +1,23 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6",
|
||||
"dom"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"hls.js-tests.ts"
|
||||
]
|
||||
}
|
||||
1
types/hls.js/tslint.json
Normal file
1
types/hls.js/tslint.json
Normal file
@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Loading…
Reference in New Issue
Block a user