youtubei.js

v5.2.1
A wrapper around YouTube's private API. Supports YouTube, YouTube Music, YouTube Kids and YouTube Studio (WIP).
yt dl ytdl youtube youtubedl youtube-dl youtube-downloader youtube-music youtube-studio and 11 more...

lint

npx eslint ./src

test

npx jest --verbose

build

npm run build:parser-map && npm run build:proto && npm run build:esm && npm run bundle:node && npm run bundle:browser && npm run bundle:browser:prod

watch

npx tsc --watch

prepare

npm run build

lint:fix

npx eslint --fix ./src

build:esm

npx tsc

build:deno

npx cpy ./src ./deno && npx cpy ./package.json ./deno && npx replace ".js';" ".ts';" ./deno -r && npx replace '.js";' '.ts";' ./deno -r && npx replace "'linkedom';" "'https://esm.sh/linkedom';" ./deno -r && npx replace "'jintr';" "'https://esm.sh/jintr';" ./deno -r && npx replace "new Jinter.default" "new Jinter" ./deno -r

build:proto

npx pb-gen-ts --entry-path="src/proto" --out-dir="src/proto/generated" --ext-in-import=".js"

bundle:node

npx esbuild ./dist/src/platform/node.js --bundle --target=node10 --keep-names --format=cjs --platform=node --outfile=./bundle/node.cjs --external:jintr --external:undici --external:linkedom --external:tslib --sourcemap --banner:js="/* eslint-disable */"

bundle:browser

npx esbuild ./dist/src/platform/web.js --banner:js="/* eslint-disable */" --bundle --target=chrome58 --keep-names --format=esm --sourcemap --define:global=globalThis --conditions=module --outfile=./bundle/browser.js --platform=browser

build:parser-map

node ./scripts/build-parser-map.cjs

bundle:browser:prod

npm run bundle:browser -- --outfile=./bundle/browser.min.js --minify

Metadata

  • MIT
  • Whatever
  • LuanRT
  • released 7/4/2023

Downloads

Maintainers