A simple Node.js youtube-dl wrapper for webpack
npm install youtube-dl-webpack[![npm][npm-image]][npm-url]
[![MIT License][mit-license-image]][mit-license-url]
[npm-url]: https://www.npmjs.com/package/youtube-dl-webpack
[npm-image]: https://img.shields.io/npm/v/youtube-dl-webpack.svg?label=npm%20version
[mit-license-url]: LICENSE
[mit-license-image]: https://camo.githubusercontent.com/d59450139b6d354f15a2252a47b457bb2cc43828/68747470733a2f2f696d672e736869656c64732e696f2f6e706d2f6c2f7365727665726c6573732e737667
A simple Node.js youtube-dl wrapper for webpack
This repository is a port version of youtube-dl-exec for webpack
- Executes any command in an efficient way.
- Use youtube-dl in webpack
npm install --save youtube-dl-webpacknpm install --save-dev youtube-dl-downloader-webpack-plugin
``js
const { YoutudeDlDownloaderWebpackPlugin } = require('youtube-dl-downloader-webpack-plugin')
module.exports = {
...
plugins: [
new YoutudeDlDownloaderWebpackPlugin({
to: 'lib', // A directory to save file
from: 'auto', // A site to download file (auto, github or website)
})
...
]
}
`
see youtube-dl-downloader-webpack-plugin to know detail.
`js
const youtubedl = require('youtube-dl-webpack')
youtubedl('https://example.com', {
dumpSingleJson: true,
noWarnings: true,
noCallHome: true,
noCheckCertificate: true,
preferFreeFormats: true,
youtubeSkipDashManifest: true,
referer: 'https://example.com',
}).then(output => console.log(output))
`
It's equivalent to:
`bash``
$ youtube-dl https://example.com --dump-single-json --no-warnings --no-call-home --no-check-certificate --prefer-free-formats --youtube-skip-dash-manifest --referer=https://example.com
We welcome your contribution in any way.