@kldzj/ytdl-dash
v1.0.0
Published
Generates DASH manifests from data gathered by ytdl-core
Downloads
1
Readme
Generates DASH manifests for YouTube videos using data from ytdl-core
.
Installation
Using yarn:
$ yarn add ytdl-core @kldzj/ytdl-dash
Using npm:
$ npm i -S ytdl-core @kldzj/ytdl-dash
Usage
import ytdl from 'ytdl-core';
import { generateDASHFromVideoInfo } from '@kldzj/ytdl-dash';
const video = await ytdl.getInfo('dQw4w9WgXcQ');
const manifest = generateDASHFromVideoInfo(video); // dash-xml string
Options
import ytdl from 'ytdl-core';
import { generateDASHFromVideoInfo } from '@kldzj/ytdl-dash';
const video = await ytdl.getInfo('dQw4w9WgXcQ');
const manifest = generateDASHFromVideoInfo(video, {
// replace all IPs in the media URLs
replaceIPs: true,
});
Credits
Thanks to FreeTubeApp for their yt-dash-manifest-generator package.