invidjs / invidjs Goto Github PK
View Code? Open in Web Editor NEWAn attempt to bring Invidious support to Node.js.
Home Page: https://invidjs.js.org/
License: GNU Affero General Public License v3.0
An attempt to bring Invidious support to Node.js.
Home Page: https://invidjs.js.org/
License: GNU Affero General Public License v3.0
API returns an error page for now.
The module will be fully ready once the following checklist is completed:
Converted to a separate issue since this will most likely be tackled post-release.
Will need to allow the user to punch a custom URL, or come up with another solution.
Fetching them will require parallel connections, most likely via aria2c
.
The fetchInstances
method is broken
test("Only a single instance should be fetched if a URL is given.", async () => {
const instances = await InvidJS.fetchInstances({
url: "https://vid.puffyan.us",
});
expect(instances).toHaveLength(1);
expect(instances[0].url).toBe("https://vid.puffyan.us");
}, 60000);
Test cases should pass
No response
We must be able to sort the instances by ping, as well as health.
Invidious docs state the following classes exist:
Extra classes:
DoppelBot's testing build could play a file fine on a Pi, but fails on Windows with permission errors.
The result produces no sound at all.
I'm using Vite, React, react-router. In a router loader, I call invidJS to fetch instances. Any function I tried, I receive the following errors.
In a route loader:
import * as invidJS from "@invidjs/invid-js"
...
const instances = await invidJS.fetchInstances()
...
Errors in the devtools:
Module "stream" has been externalized for browser compatibility. Cannot access "stream.Stream" in client code. See http://vitejs.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.
browser-external:fs:9 Uncaught TypeError: Cannot convert a Symbol value to a string
at Object.get (browser-external:fs:9:102)
at node_modules/graceful-fs/graceful-fs.js (graceful-fs.js:43:6)
at __require2 (chunk-OZI5HTJH.js?v=4f187028:15:50)
at node_modules/@invidjs/invid-js/node_modules/fs-extra/lib/fs/index.js (index.js:5:12)
at __require2 (chunk-OZI5HTJH.js?v=4f187028:15:50)
at node_modules/@invidjs/invid-js/node_modules/fs-extra/lib/index.js (index.js:5:6)
at __require2 (chunk-OZI5HTJH.js?v=4f187028:15:50)
at index.mjs:222:16
get @ browser-external:fs:9
node_modules/graceful-fs/graceful-fs.js @ graceful-fs.js:43
__require2 @ chunk-OZI5HTJH.js?v=4f187028:15
node_modules/@invidjs/invid-js/node_modules/fs-extra/lib/fs/index.js @ index.js:5
__require2 @ chunk-OZI5HTJH.js?v=4f187028:15
node_modules/@invidjs/invid-js/node_modules/fs-extra/lib/index.js @ index.js:5
__require2 @ chunk-OZI5HTJH.js?v=4f187028:15
(anonymous) @ index.mjs:222
Fetch instances data.
https://vitejs.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.