youtube-loader

1.1.2 • Public • Published

youtube-dl.js

Build Status npm version

Installation

Requirements

FFmpeg has to be installed to PATH

To install youtube-dl.js run npm install youtube-loader --save

To update the youtube-dl binary, run npm run updateytdl or run the setup script (node setup.js)

Usage

const ytdl = require("youtube-loader");
 
let url = "https://youtu.be/q5weS3aY-Qc",
    filename = `${new Date().getTime()}.%(ext)s`,
    args = ["-o", filename, "-x", "--audio-format=mp3", "--restrict-filenames", "--external-downloader=ffmpeg", "--audio-quality=96k"],
    options = {status: (data) => console.log(data)};
 
ytdl(url, args, options)
  .then(data => {
    console.log(data);
  })
  .catch(err => {
    console.error(err);
  });

THX

for Delivator, he wrote this, i forked it to add status callbacks ;)

Readme

Keywords

Package Sidebar

Install

npm i youtube-loader

Weekly Downloads

1

Version

1.1.2

License

ISC

Unpacked Size

6.54 kB

Total Files

7

Last publish

Collaborators

  • chwzr