mirror of
https://github.com/movie-web/providers.git
synced 2025-09-13 14:53:24 +00:00
spelling/grammar
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
# `ProviderControls.runAll`
|
||||
|
||||
Run all providers one by one in order of their built-in ranking.
|
||||
You can attach events if you need to know what is going on while its processing.
|
||||
You can attach events if you need to know what is going on while it is processing.
|
||||
|
||||
## Example
|
||||
|
||||
@@ -20,7 +20,7 @@ const stream = await providers.runAll({
|
||||
})
|
||||
|
||||
// scrape a stream, but prioritize flixhq above all
|
||||
// (other scrapers are stil ran if flixhq fails, it just has priority)
|
||||
// (other scrapers are still run if flixhq fails, it just has priority)
|
||||
const flixhqStream = await providers.runAll({
|
||||
media: media,
|
||||
sourceOrder: ['flixhq']
|
||||
@@ -33,12 +33,12 @@ const flixhqStream = await providers.runAll({
|
||||
function runAll(runnerOps: RunnerOptions): Promise<RunOutput | null>;
|
||||
|
||||
interface RunnerOptions {
|
||||
// overwrite the order of sources to run. list of ids
|
||||
// any omitted ids are in added to the end in order of rank (highest first)
|
||||
// overwrite the order of sources to run. List of IDs
|
||||
// any omitted IDs are added to the end in order of rank (highest first)
|
||||
sourceOrder?: string[];
|
||||
|
||||
// overwrite the order of embeds to run. list of ids
|
||||
// any omitted ids are in added to the end in order of rank (highest first)
|
||||
// overwrite the order of embeds to run. List of IDs
|
||||
// any omitted IDs are added to the end in order of rank (highest first)
|
||||
embedOrder?: string[];
|
||||
|
||||
// object of event functions
|
||||
@@ -49,13 +49,13 @@ interface RunnerOptions {
|
||||
}
|
||||
|
||||
type RunOutput = {
|
||||
// source scraper id
|
||||
// source scraper ID
|
||||
sourceId: string;
|
||||
|
||||
// if from an embed, this is the embed scraper id
|
||||
// if from an embed, this is the embed scraper ID
|
||||
embedId?: string;
|
||||
|
||||
// the outputed stream
|
||||
// the emitted stream
|
||||
stream: Stream;
|
||||
};
|
||||
```
|
||||
|
Reference in New Issue
Block a user