Git Product home page Git Product logo

play-dl's Introduction

Play-dl

A light-weight YouTube, SoundCloud, Spotify and Deezer streaming and searching library.

  • Search by video, playlist/album, channel/artist
  • Stream audio from YouTube and SoundCloud

Why play-dl ?

ytdl-core has some issues with miniget and also stream abort issues. On the other hand, youtube-dl is a perfect alternative but it takes time to launch. Hence, play-dl is created to avoid these issues along with providing comparatively faster performance than others.

Discord NPM

Support

You can contact us for support on our chat server.

Installation

Node.js 16.0.0 or newer is required.

npm install play-dl@latest
pnpm add play-dl@latest
yarn add play-dl@latest

Importing

TypeScript:

import play from 'play-dl'; // Everything

import { video_basic_info, stream } from 'play-dl'; // Individual functions

CommonJS modules:

const play = require('play-dl'); // Everything

// Individual functions by using destructuring
const { video_basic_info, stream } = require('play-dl');

ES6 modules:

import play from 'play-dl'; // Everything

import { video_basic_info, stream } from 'play-dl'; // Individual functions

Compatibility issues - discord-player

Because discord-player doesn't work with raw opus packets you need to enable the compatibility mode in play-dl, if you want to use both frameworks together.

  • To fix the playback of YouTube videos with discord-player, you can disable some of play-dl's optimisations and fixes by setting the discordPlayerCompatibility option for stream and stream_from_info to true

  • The discordPlayerCompatiblity option might break the playback of long YouTube videos.

  • Even with the discordPlayerCompatibility option set you will not be able to use the seek option for stream and stream_from_info.

play-dl's People

Contributors

iim-ayush avatar absidue avatar dependabot[bot] avatar ataritom avatar cjh980402 avatar kaisic1224 avatar tr1ckydev avatar github-actions[bot] avatar darker-ink avatar ducktrshessami avatar karyeet avatar kingrainbow44 avatar vladexa avatar kane50613 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.