rahad-media-downloader 2.1.12 → 2.1.14
Sign up to get free protection for your applications and to get access to all the features.
- package/.cache/replit/modules/nodejs-20.res +1 -0
- package/.cache/replit/modules/replit.res +1 -0
- package/.cache/typescript/5.4/node_modules/.package-lock.json +185 -0
- package/.cache/typescript/5.4/node_modules/@types/caseless/LICENSE +21 -0
- package/.cache/typescript/5.4/node_modules/@types/caseless/README.md +48 -0
- package/.cache/typescript/5.4/node_modules/@types/caseless/index.d.ts +29 -0
- package/.cache/typescript/5.4/node_modules/@types/caseless/package.json +35 -0
- package/.cache/typescript/5.4/node_modules/@types/domhandler/LICENSE +21 -0
- package/.cache/typescript/5.4/node_modules/@types/domhandler/README.md +92 -0
- package/.cache/typescript/5.4/node_modules/@types/domhandler/index.d.ts +73 -0
- package/.cache/typescript/5.4/node_modules/@types/domhandler/package.json +25 -0
- package/.cache/typescript/5.4/node_modules/@types/domutils/LICENSE +21 -0
- package/.cache/typescript/5.4/node_modules/@types/domutils/README.md +15 -0
- package/.cache/typescript/5.4/node_modules/@types/domutils/index.d.ts +124 -0
- package/.cache/typescript/5.4/node_modules/@types/domutils/package.json +27 -0
- package/.cache/typescript/5.4/node_modules/@types/htmlparser2/LICENSE +21 -0
- package/.cache/typescript/5.4/node_modules/@types/htmlparser2/README.md +15 -0
- package/.cache/typescript/5.4/node_modules/@types/htmlparser2/index.d.ts +120 -0
- package/.cache/typescript/5.4/node_modules/@types/htmlparser2/package.json +45 -0
- package/.cache/typescript/5.4/node_modules/@types/node/LICENSE +21 -0
- package/.cache/typescript/5.4/node_modules/@types/node/README.md +15 -0
- package/.cache/typescript/5.4/node_modules/@types/node/assert/strict.d.ts +8 -0
- package/.cache/typescript/5.4/node_modules/@types/node/assert.d.ts +1040 -0
- package/.cache/typescript/5.4/node_modules/@types/node/async_hooks.d.ts +541 -0
- package/.cache/typescript/5.4/node_modules/@types/node/buffer.d.ts +2363 -0
- package/.cache/typescript/5.4/node_modules/@types/node/child_process.d.ts +1542 -0
- package/.cache/typescript/5.4/node_modules/@types/node/cluster.d.ts +578 -0
- package/.cache/typescript/5.4/node_modules/@types/node/console.d.ts +452 -0
- package/.cache/typescript/5.4/node_modules/@types/node/constants.d.ts +19 -0
- package/.cache/typescript/5.4/node_modules/@types/node/crypto.d.ts +4522 -0
- package/.cache/typescript/5.4/node_modules/@types/node/dgram.d.ts +596 -0
- package/.cache/typescript/5.4/node_modules/@types/node/diagnostics_channel.d.ts +545 -0
- package/.cache/typescript/5.4/node_modules/@types/node/dns/promises.d.ts +473 -0
- package/.cache/typescript/5.4/node_modules/@types/node/dns.d.ts +853 -0
- package/.cache/typescript/5.4/node_modules/@types/node/dom-events.d.ts +124 -0
- package/.cache/typescript/5.4/node_modules/@types/node/domain.d.ts +170 -0
- package/.cache/typescript/5.4/node_modules/@types/node/events.d.ts +884 -0
- package/.cache/typescript/5.4/node_modules/@types/node/fs/promises.d.ts +1245 -0
- package/.cache/typescript/5.4/node_modules/@types/node/fs.d.ts +4317 -0
- package/.cache/typescript/5.4/node_modules/@types/node/globals.d.ts +411 -0
- package/.cache/typescript/5.4/node_modules/@types/node/globals.global.d.ts +1 -0
- package/.cache/typescript/5.4/node_modules/@types/node/http.d.ts +1889 -0
- package/.cache/typescript/5.4/node_modules/@types/node/http2.d.ts +2418 -0
- package/.cache/typescript/5.4/node_modules/@types/node/https.d.ts +550 -0
- package/.cache/typescript/5.4/node_modules/@types/node/index.d.ts +89 -0
- package/.cache/typescript/5.4/node_modules/@types/node/inspector.d.ts +2746 -0
- package/.cache/typescript/5.4/node_modules/@types/node/module.d.ts +315 -0
- package/.cache/typescript/5.4/node_modules/@types/node/net.d.ts +996 -0
- package/.cache/typescript/5.4/node_modules/@types/node/os.d.ts +495 -0
- package/.cache/typescript/5.4/node_modules/@types/node/package.json +217 -0
- package/.cache/typescript/5.4/node_modules/@types/node/path.d.ts +191 -0
- package/.cache/typescript/5.4/node_modules/@types/node/perf_hooks.d.ts +645 -0
- package/.cache/typescript/5.4/node_modules/@types/node/process.d.ts +1747 -0
- package/.cache/typescript/5.4/node_modules/@types/node/punycode.d.ts +117 -0
- package/.cache/typescript/5.4/node_modules/@types/node/querystring.d.ts +153 -0
- package/.cache/typescript/5.4/node_modules/@types/node/readline/promises.d.ts +150 -0
- package/.cache/typescript/5.4/node_modules/@types/node/readline.d.ts +540 -0
- package/.cache/typescript/5.4/node_modules/@types/node/repl.d.ts +430 -0
- package/.cache/typescript/5.4/node_modules/@types/node/sea.d.ts +153 -0
- package/.cache/typescript/5.4/node_modules/@types/node/stream/consumers.d.ts +12 -0
- package/.cache/typescript/5.4/node_modules/@types/node/stream/promises.d.ts +83 -0
- package/.cache/typescript/5.4/node_modules/@types/node/stream/web.d.ts +367 -0
- package/.cache/typescript/5.4/node_modules/@types/node/stream.d.ts +1707 -0
- package/.cache/typescript/5.4/node_modules/@types/node/string_decoder.d.ts +67 -0
- package/.cache/typescript/5.4/node_modules/@types/node/test.d.ts +1470 -0
- package/.cache/typescript/5.4/node_modules/@types/node/timers/promises.d.ts +97 -0
- package/.cache/typescript/5.4/node_modules/@types/node/timers.d.ts +240 -0
- package/.cache/typescript/5.4/node_modules/@types/node/tls.d.ts +1217 -0
- package/.cache/typescript/5.4/node_modules/@types/node/trace_events.d.ts +197 -0
- package/.cache/typescript/5.4/node_modules/@types/node/tty.d.ts +208 -0
- package/.cache/typescript/5.4/node_modules/@types/node/url.d.ts +944 -0
- package/.cache/typescript/5.4/node_modules/@types/node/util.d.ts +2276 -0
- package/.cache/typescript/5.4/node_modules/@types/node/v8.d.ts +764 -0
- package/.cache/typescript/5.4/node_modules/@types/node/vm.d.ts +921 -0
- package/.cache/typescript/5.4/node_modules/@types/node/wasi.d.ts +181 -0
- package/.cache/typescript/5.4/node_modules/@types/node/worker_threads.d.ts +691 -0
- package/.cache/typescript/5.4/node_modules/@types/node/zlib.d.ts +530 -0
- package/.cache/typescript/5.4/node_modules/@types/node-fetch/LICENSE +21 -0
- package/.cache/typescript/5.4/node_modules/@types/node-fetch/README.md +15 -0
- package/.cache/typescript/5.4/node_modules/@types/node-fetch/externals.d.ts +32 -0
- package/.cache/typescript/5.4/node_modules/@types/node-fetch/index.d.ts +238 -0
- package/.cache/typescript/5.4/node_modules/@types/node-fetch/package.json +83 -0
- package/.cache/typescript/5.4/node_modules/@types/qs/LICENSE +21 -0
- package/.cache/typescript/5.4/node_modules/@types/qs/README.md +15 -0
- package/.cache/typescript/5.4/node_modules/@types/qs/index.d.ts +79 -0
- package/.cache/typescript/5.4/node_modules/@types/qs/package.json +65 -0
- package/.cache/typescript/5.4/node_modules/@types/request/LICENSE +21 -0
- package/.cache/typescript/5.4/node_modules/@types/request/README.md +15 -0
- package/.cache/typescript/5.4/node_modules/@types/request/index.d.ts +395 -0
- package/.cache/typescript/5.4/node_modules/@types/request/node_modules/form-data/License +19 -0
- package/.cache/typescript/5.4/node_modules/@types/request/node_modules/form-data/README.md +350 -0
- package/.cache/typescript/5.4/node_modules/@types/request/node_modules/form-data/README.md.bak +350 -0
- package/.cache/typescript/5.4/node_modules/@types/request/node_modules/form-data/index.d.ts +51 -0
- package/.cache/typescript/5.4/node_modules/@types/request/node_modules/form-data/lib/browser.js +2 -0
- package/.cache/typescript/5.4/node_modules/@types/request/node_modules/form-data/lib/form_data.js +483 -0
- package/.cache/typescript/5.4/node_modules/@types/request/node_modules/form-data/lib/populate.js +10 -0
- package/.cache/typescript/5.4/node_modules/@types/request/node_modules/form-data/package.json +68 -0
- package/.cache/typescript/5.4/node_modules/@types/request/package.json +70 -0
- package/.cache/typescript/5.4/node_modules/@types/tough-cookie/LICENSE +21 -0
- package/.cache/typescript/5.4/node_modules/@types/tough-cookie/README.md +15 -0
- package/.cache/typescript/5.4/node_modules/@types/tough-cookie/index.d.ts +321 -0
- package/.cache/typescript/5.4/node_modules/@types/tough-cookie/package.json +35 -0
- package/.cache/typescript/5.4/node_modules/asynckit/LICENSE +21 -0
- package/.cache/typescript/5.4/node_modules/asynckit/README.md +233 -0
- package/.cache/typescript/5.4/node_modules/asynckit/bench.js +76 -0
- package/.cache/typescript/5.4/node_modules/asynckit/index.js +6 -0
- package/.cache/typescript/5.4/node_modules/asynckit/lib/abort.js +29 -0
- package/.cache/typescript/5.4/node_modules/asynckit/lib/async.js +34 -0
- package/.cache/typescript/5.4/node_modules/asynckit/lib/defer.js +26 -0
- package/.cache/typescript/5.4/node_modules/asynckit/lib/iterate.js +75 -0
- package/.cache/typescript/5.4/node_modules/asynckit/lib/readable_asynckit.js +91 -0
- package/.cache/typescript/5.4/node_modules/asynckit/lib/readable_parallel.js +25 -0
- package/.cache/typescript/5.4/node_modules/asynckit/lib/readable_serial.js +25 -0
- package/.cache/typescript/5.4/node_modules/asynckit/lib/readable_serial_ordered.js +29 -0
- package/.cache/typescript/5.4/node_modules/asynckit/lib/state.js +37 -0
- package/.cache/typescript/5.4/node_modules/asynckit/lib/streamify.js +141 -0
- package/.cache/typescript/5.4/node_modules/asynckit/lib/terminator.js +29 -0
- package/.cache/typescript/5.4/node_modules/asynckit/package.json +63 -0
- package/.cache/typescript/5.4/node_modules/asynckit/parallel.js +43 -0
- package/.cache/typescript/5.4/node_modules/asynckit/serial.js +17 -0
- package/.cache/typescript/5.4/node_modules/asynckit/serialOrdered.js +75 -0
- package/.cache/typescript/5.4/node_modules/asynckit/stream.js +21 -0
- package/.cache/typescript/5.4/node_modules/combined-stream/License +19 -0
- package/.cache/typescript/5.4/node_modules/combined-stream/Readme.md +138 -0
- package/.cache/typescript/5.4/node_modules/combined-stream/lib/combined_stream.js +208 -0
- package/.cache/typescript/5.4/node_modules/combined-stream/package.json +25 -0
- package/.cache/typescript/5.4/node_modules/combined-stream/yarn.lock +17 -0
- package/.cache/typescript/5.4/node_modules/delayed-stream/License +19 -0
- package/.cache/typescript/5.4/node_modules/delayed-stream/Makefile +7 -0
- package/.cache/typescript/5.4/node_modules/delayed-stream/Readme.md +141 -0
- package/.cache/typescript/5.4/node_modules/delayed-stream/lib/delayed_stream.js +107 -0
- package/.cache/typescript/5.4/node_modules/delayed-stream/package.json +27 -0
- package/.cache/typescript/5.4/node_modules/domelementtype/LICENSE +11 -0
- package/.cache/typescript/5.4/node_modules/domelementtype/index.js +15 -0
- package/.cache/typescript/5.4/node_modules/domelementtype/package.json +16 -0
- package/.cache/typescript/5.4/node_modules/domelementtype/readme.md +1 -0
- package/.cache/typescript/5.4/node_modules/domhandler/.travis.yml +6 -0
- package/.cache/typescript/5.4/node_modules/domhandler/LICENSE +11 -0
- package/.cache/typescript/5.4/node_modules/domhandler/index.js +217 -0
- package/.cache/typescript/5.4/node_modules/domhandler/lib/element.js +20 -0
- package/.cache/typescript/5.4/node_modules/domhandler/lib/node.js +44 -0
- package/.cache/typescript/5.4/node_modules/domhandler/package.json +41 -0
- package/.cache/typescript/5.4/node_modules/domhandler/readme.md +116 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/01-basic.json +57 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/02-single_tag_1.json +21 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/03-single_tag_2.json +21 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/04-unescaped_in_script.json +27 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/05-tags_in_comment.json +18 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/06-comment_in_script.json +18 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/07-unescaped_in_style.json +20 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/08-extra_spaces_in_tag.json +20 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/09-unquoted_attrib.json +20 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/10-singular_attribute.json +15 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/11-text_outside_tags.json +40 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/12-text_only.json +11 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/13-comment_in_text.json +19 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/14-comment_in_text_in_script.json +18 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/15-non-verbose.json +22 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/16-normalize_whitespace.json +47 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/17-xml_namespace.json +18 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/18-enforce_empty_tags.json +16 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/19-ignore_empty_tags.json +20 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/20-template_script_tags.json +20 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/21-conditional_comments.json +15 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/22-lowercase_tags.json +41 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/23-dom-lvl1.json +131 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/24-with-start-indices.json +85 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/cases/25-with-end-indices.json +86 -0
- package/.cache/typescript/5.4/node_modules/domhandler/test/tests.js +60 -0
- package/.cache/typescript/5.4/node_modules/form-data/License +19 -0
- package/.cache/typescript/5.4/node_modules/form-data/README.md.bak +358 -0
- package/.cache/typescript/5.4/node_modules/form-data/Readme.md +358 -0
- package/.cache/typescript/5.4/node_modules/form-data/index.d.ts +62 -0
- package/.cache/typescript/5.4/node_modules/form-data/lib/browser.js +2 -0
- package/.cache/typescript/5.4/node_modules/form-data/lib/form_data.js +501 -0
- package/.cache/typescript/5.4/node_modules/form-data/lib/populate.js +10 -0
- package/.cache/typescript/5.4/node_modules/form-data/package.json +68 -0
- package/.cache/typescript/5.4/node_modules/mime-db/HISTORY.md +507 -0
- package/.cache/typescript/5.4/node_modules/mime-db/LICENSE +23 -0
- package/.cache/typescript/5.4/node_modules/mime-db/README.md +100 -0
- package/.cache/typescript/5.4/node_modules/mime-db/db.json +8519 -0
- package/.cache/typescript/5.4/node_modules/mime-db/index.js +12 -0
- package/.cache/typescript/5.4/node_modules/mime-db/package.json +60 -0
- package/.cache/typescript/5.4/node_modules/mime-types/HISTORY.md +397 -0
- package/.cache/typescript/5.4/node_modules/mime-types/LICENSE +23 -0
- package/.cache/typescript/5.4/node_modules/mime-types/README.md +113 -0
- package/.cache/typescript/5.4/node_modules/mime-types/index.js +188 -0
- package/.cache/typescript/5.4/node_modules/mime-types/package.json +44 -0
- package/.cache/typescript/5.4/node_modules/types-registry/README.md +2 -0
- package/.cache/typescript/5.4/node_modules/types-registry/index.json +1 -0
- package/.cache/typescript/5.4/node_modules/types-registry/package.json +20 -0
- package/.cache/typescript/5.4/node_modules/undici-types/README.md +6 -0
- package/.cache/typescript/5.4/node_modules/undici-types/agent.d.ts +31 -0
- package/.cache/typescript/5.4/node_modules/undici-types/api.d.ts +43 -0
- package/.cache/typescript/5.4/node_modules/undici-types/balanced-pool.d.ts +18 -0
- package/.cache/typescript/5.4/node_modules/undici-types/cache.d.ts +36 -0
- package/.cache/typescript/5.4/node_modules/undici-types/client.d.ts +97 -0
- package/.cache/typescript/5.4/node_modules/undici-types/connector.d.ts +34 -0
- package/.cache/typescript/5.4/node_modules/undici-types/content-type.d.ts +21 -0
- package/.cache/typescript/5.4/node_modules/undici-types/cookies.d.ts +28 -0
- package/.cache/typescript/5.4/node_modules/undici-types/diagnostics-channel.d.ts +67 -0
- package/.cache/typescript/5.4/node_modules/undici-types/dispatcher.d.ts +241 -0
- package/.cache/typescript/5.4/node_modules/undici-types/errors.d.ts +128 -0
- package/.cache/typescript/5.4/node_modules/undici-types/fetch.d.ts +209 -0
- package/.cache/typescript/5.4/node_modules/undici-types/file.d.ts +39 -0
- package/.cache/typescript/5.4/node_modules/undici-types/filereader.d.ts +54 -0
- package/.cache/typescript/5.4/node_modules/undici-types/formdata.d.ts +108 -0
- package/.cache/typescript/5.4/node_modules/undici-types/global-dispatcher.d.ts +9 -0
- package/.cache/typescript/5.4/node_modules/undici-types/global-origin.d.ts +7 -0
- package/.cache/typescript/5.4/node_modules/undici-types/handlers.d.ts +9 -0
- package/.cache/typescript/5.4/node_modules/undici-types/header.d.ts +4 -0
- package/.cache/typescript/5.4/node_modules/undici-types/index.d.ts +63 -0
- package/.cache/typescript/5.4/node_modules/undici-types/interceptors.d.ts +5 -0
- package/.cache/typescript/5.4/node_modules/undici-types/mock-agent.d.ts +50 -0
- package/.cache/typescript/5.4/node_modules/undici-types/mock-client.d.ts +25 -0
- package/.cache/typescript/5.4/node_modules/undici-types/mock-errors.d.ts +12 -0
- package/.cache/typescript/5.4/node_modules/undici-types/mock-interceptor.d.ts +93 -0
- package/.cache/typescript/5.4/node_modules/undici-types/mock-pool.d.ts +25 -0
- package/.cache/typescript/5.4/node_modules/undici-types/package.json +55 -0
- package/.cache/typescript/5.4/node_modules/undici-types/patch.d.ts +71 -0
- package/.cache/typescript/5.4/node_modules/undici-types/pool-stats.d.ts +19 -0
- package/.cache/typescript/5.4/node_modules/undici-types/pool.d.ts +28 -0
- package/.cache/typescript/5.4/node_modules/undici-types/proxy-agent.d.ts +30 -0
- package/.cache/typescript/5.4/node_modules/undici-types/readable.d.ts +61 -0
- package/.cache/typescript/5.4/node_modules/undici-types/webidl.d.ts +220 -0
- package/.cache/typescript/5.4/node_modules/undici-types/websocket.d.ts +131 -0
- package/.cache/typescript/5.4/package-lock.json +197 -0
- package/.cache/typescript/5.4/package.json +1 -0
- package/README.md +61 -2
- package/index.js +1 -1
- package/package.json +11 -2
- package/.cache/replit/modules/nodejs-20:v36-20240502-f4453db.res +0 -1
- package/.cache/replit/modules/replit:v9-20240429-0325cbb.res +0 -1
@@ -0,0 +1,220 @@
|
|
1
|
+
// These types are not exported, and are only used internally
|
2
|
+
|
3
|
+
/**
|
4
|
+
* Take in an unknown value and return one that is of type T
|
5
|
+
*/
|
6
|
+
type Converter<T> = (object: unknown) => T
|
7
|
+
|
8
|
+
type SequenceConverter<T> = (object: unknown) => T[]
|
9
|
+
|
10
|
+
type RecordConverter<K extends string, V> = (object: unknown) => Record<K, V>
|
11
|
+
|
12
|
+
interface ConvertToIntOpts {
|
13
|
+
clamp?: boolean
|
14
|
+
enforceRange?: boolean
|
15
|
+
}
|
16
|
+
|
17
|
+
interface WebidlErrors {
|
18
|
+
exception (opts: { header: string, message: string }): TypeError
|
19
|
+
/**
|
20
|
+
* @description Throw an error when conversion from one type to another has failed
|
21
|
+
*/
|
22
|
+
conversionFailed (opts: {
|
23
|
+
prefix: string
|
24
|
+
argument: string
|
25
|
+
types: string[]
|
26
|
+
}): TypeError
|
27
|
+
/**
|
28
|
+
* @description Throw an error when an invalid argument is provided
|
29
|
+
*/
|
30
|
+
invalidArgument (opts: {
|
31
|
+
prefix: string
|
32
|
+
value: string
|
33
|
+
type: string
|
34
|
+
}): TypeError
|
35
|
+
}
|
36
|
+
|
37
|
+
interface WebidlUtil {
|
38
|
+
/**
|
39
|
+
* @see https://tc39.es/ecma262/#sec-ecmascript-data-types-and-values
|
40
|
+
*/
|
41
|
+
Type (object: unknown):
|
42
|
+
| 'Undefined'
|
43
|
+
| 'Boolean'
|
44
|
+
| 'String'
|
45
|
+
| 'Symbol'
|
46
|
+
| 'Number'
|
47
|
+
| 'BigInt'
|
48
|
+
| 'Null'
|
49
|
+
| 'Object'
|
50
|
+
|
51
|
+
/**
|
52
|
+
* @see https://webidl.spec.whatwg.org/#abstract-opdef-converttoint
|
53
|
+
*/
|
54
|
+
ConvertToInt (
|
55
|
+
V: unknown,
|
56
|
+
bitLength: number,
|
57
|
+
signedness: 'signed' | 'unsigned',
|
58
|
+
opts?: ConvertToIntOpts
|
59
|
+
): number
|
60
|
+
|
61
|
+
/**
|
62
|
+
* @see https://webidl.spec.whatwg.org/#abstract-opdef-converttoint
|
63
|
+
*/
|
64
|
+
IntegerPart (N: number): number
|
65
|
+
}
|
66
|
+
|
67
|
+
interface WebidlConverters {
|
68
|
+
/**
|
69
|
+
* @see https://webidl.spec.whatwg.org/#es-DOMString
|
70
|
+
*/
|
71
|
+
DOMString (V: unknown, opts?: {
|
72
|
+
legacyNullToEmptyString: boolean
|
73
|
+
}): string
|
74
|
+
|
75
|
+
/**
|
76
|
+
* @see https://webidl.spec.whatwg.org/#es-ByteString
|
77
|
+
*/
|
78
|
+
ByteString (V: unknown): string
|
79
|
+
|
80
|
+
/**
|
81
|
+
* @see https://webidl.spec.whatwg.org/#es-USVString
|
82
|
+
*/
|
83
|
+
USVString (V: unknown): string
|
84
|
+
|
85
|
+
/**
|
86
|
+
* @see https://webidl.spec.whatwg.org/#es-boolean
|
87
|
+
*/
|
88
|
+
boolean (V: unknown): boolean
|
89
|
+
|
90
|
+
/**
|
91
|
+
* @see https://webidl.spec.whatwg.org/#es-any
|
92
|
+
*/
|
93
|
+
any <Value>(V: Value): Value
|
94
|
+
|
95
|
+
/**
|
96
|
+
* @see https://webidl.spec.whatwg.org/#es-long-long
|
97
|
+
*/
|
98
|
+
['long long'] (V: unknown): number
|
99
|
+
|
100
|
+
/**
|
101
|
+
* @see https://webidl.spec.whatwg.org/#es-unsigned-long-long
|
102
|
+
*/
|
103
|
+
['unsigned long long'] (V: unknown): number
|
104
|
+
|
105
|
+
/**
|
106
|
+
* @see https://webidl.spec.whatwg.org/#es-unsigned-long
|
107
|
+
*/
|
108
|
+
['unsigned long'] (V: unknown): number
|
109
|
+
|
110
|
+
/**
|
111
|
+
* @see https://webidl.spec.whatwg.org/#es-unsigned-short
|
112
|
+
*/
|
113
|
+
['unsigned short'] (V: unknown, opts?: ConvertToIntOpts): number
|
114
|
+
|
115
|
+
/**
|
116
|
+
* @see https://webidl.spec.whatwg.org/#idl-ArrayBuffer
|
117
|
+
*/
|
118
|
+
ArrayBuffer (V: unknown): ArrayBufferLike
|
119
|
+
ArrayBuffer (V: unknown, opts: { allowShared: false }): ArrayBuffer
|
120
|
+
|
121
|
+
/**
|
122
|
+
* @see https://webidl.spec.whatwg.org/#es-buffer-source-types
|
123
|
+
*/
|
124
|
+
TypedArray (
|
125
|
+
V: unknown,
|
126
|
+
TypedArray: NodeJS.TypedArray | ArrayBufferLike
|
127
|
+
): NodeJS.TypedArray | ArrayBufferLike
|
128
|
+
TypedArray (
|
129
|
+
V: unknown,
|
130
|
+
TypedArray: NodeJS.TypedArray | ArrayBufferLike,
|
131
|
+
opts?: { allowShared: false }
|
132
|
+
): NodeJS.TypedArray | ArrayBuffer
|
133
|
+
|
134
|
+
/**
|
135
|
+
* @see https://webidl.spec.whatwg.org/#es-buffer-source-types
|
136
|
+
*/
|
137
|
+
DataView (V: unknown, opts?: { allowShared: boolean }): DataView
|
138
|
+
|
139
|
+
/**
|
140
|
+
* @see https://webidl.spec.whatwg.org/#BufferSource
|
141
|
+
*/
|
142
|
+
BufferSource (
|
143
|
+
V: unknown,
|
144
|
+
opts?: { allowShared: boolean }
|
145
|
+
): NodeJS.TypedArray | ArrayBufferLike | DataView
|
146
|
+
|
147
|
+
['sequence<ByteString>']: SequenceConverter<string>
|
148
|
+
|
149
|
+
['sequence<sequence<ByteString>>']: SequenceConverter<string[]>
|
150
|
+
|
151
|
+
['record<ByteString, ByteString>']: RecordConverter<string, string>
|
152
|
+
|
153
|
+
[Key: string]: (...args: any[]) => unknown
|
154
|
+
}
|
155
|
+
|
156
|
+
export interface Webidl {
|
157
|
+
errors: WebidlErrors
|
158
|
+
util: WebidlUtil
|
159
|
+
converters: WebidlConverters
|
160
|
+
|
161
|
+
/**
|
162
|
+
* @description Performs a brand-check on {@param V} to ensure it is a
|
163
|
+
* {@param cls} object.
|
164
|
+
*/
|
165
|
+
brandCheck <Interface>(V: unknown, cls: Interface, opts?: { strict?: boolean }): asserts V is Interface
|
166
|
+
|
167
|
+
/**
|
168
|
+
* @see https://webidl.spec.whatwg.org/#es-sequence
|
169
|
+
* @description Convert a value, V, to a WebIDL sequence type.
|
170
|
+
*/
|
171
|
+
sequenceConverter <Type>(C: Converter<Type>): SequenceConverter<Type>
|
172
|
+
|
173
|
+
illegalConstructor (): never
|
174
|
+
|
175
|
+
/**
|
176
|
+
* @see https://webidl.spec.whatwg.org/#es-to-record
|
177
|
+
* @description Convert a value, V, to a WebIDL record type.
|
178
|
+
*/
|
179
|
+
recordConverter <K extends string, V>(
|
180
|
+
keyConverter: Converter<K>,
|
181
|
+
valueConverter: Converter<V>
|
182
|
+
): RecordConverter<K, V>
|
183
|
+
|
184
|
+
/**
|
185
|
+
* Similar to {@link Webidl.brandCheck} but allows skipping the check if third party
|
186
|
+
* interfaces are allowed.
|
187
|
+
*/
|
188
|
+
interfaceConverter <Interface>(cls: Interface): (
|
189
|
+
V: unknown,
|
190
|
+
opts?: { strict: boolean }
|
191
|
+
) => asserts V is typeof cls
|
192
|
+
|
193
|
+
// TODO(@KhafraDev): a type could likely be implemented that can infer the return type
|
194
|
+
// from the converters given?
|
195
|
+
/**
|
196
|
+
* Converts a value, V, to a WebIDL dictionary types. Allows limiting which keys are
|
197
|
+
* allowed, values allowed, optional and required keys. Auto converts the value to
|
198
|
+
* a type given a converter.
|
199
|
+
*/
|
200
|
+
dictionaryConverter (converters: {
|
201
|
+
key: string,
|
202
|
+
defaultValue?: unknown,
|
203
|
+
required?: boolean,
|
204
|
+
converter: (...args: unknown[]) => unknown,
|
205
|
+
allowedValues?: unknown[]
|
206
|
+
}[]): (V: unknown) => Record<string, unknown>
|
207
|
+
|
208
|
+
/**
|
209
|
+
* @see https://webidl.spec.whatwg.org/#idl-nullable-type
|
210
|
+
* @description allows a type, V, to be null
|
211
|
+
*/
|
212
|
+
nullableConverter <T>(
|
213
|
+
converter: Converter<T>
|
214
|
+
): (V: unknown) => ReturnType<typeof converter> | null
|
215
|
+
|
216
|
+
argumentLengthCheck (args: { length: number }, min: number, context: {
|
217
|
+
header: string
|
218
|
+
message?: string
|
219
|
+
}): void
|
220
|
+
}
|
@@ -0,0 +1,131 @@
|
|
1
|
+
/// <reference types="node" />
|
2
|
+
|
3
|
+
import type { Blob } from 'buffer'
|
4
|
+
import type { MessagePort } from 'worker_threads'
|
5
|
+
import {
|
6
|
+
EventTarget,
|
7
|
+
Event,
|
8
|
+
EventInit,
|
9
|
+
EventListenerOptions,
|
10
|
+
AddEventListenerOptions,
|
11
|
+
EventListenerOrEventListenerObject
|
12
|
+
} from './patch'
|
13
|
+
import Dispatcher from './dispatcher'
|
14
|
+
import { HeadersInit } from './fetch'
|
15
|
+
|
16
|
+
export type BinaryType = 'blob' | 'arraybuffer'
|
17
|
+
|
18
|
+
interface WebSocketEventMap {
|
19
|
+
close: CloseEvent
|
20
|
+
error: Event
|
21
|
+
message: MessageEvent
|
22
|
+
open: Event
|
23
|
+
}
|
24
|
+
|
25
|
+
interface WebSocket extends EventTarget {
|
26
|
+
binaryType: BinaryType
|
27
|
+
|
28
|
+
readonly bufferedAmount: number
|
29
|
+
readonly extensions: string
|
30
|
+
|
31
|
+
onclose: ((this: WebSocket, ev: WebSocketEventMap['close']) => any) | null
|
32
|
+
onerror: ((this: WebSocket, ev: WebSocketEventMap['error']) => any) | null
|
33
|
+
onmessage: ((this: WebSocket, ev: WebSocketEventMap['message']) => any) | null
|
34
|
+
onopen: ((this: WebSocket, ev: WebSocketEventMap['open']) => any) | null
|
35
|
+
|
36
|
+
readonly protocol: string
|
37
|
+
readonly readyState: number
|
38
|
+
readonly url: string
|
39
|
+
|
40
|
+
close(code?: number, reason?: string): void
|
41
|
+
send(data: string | ArrayBufferLike | Blob | ArrayBufferView): void
|
42
|
+
|
43
|
+
readonly CLOSED: number
|
44
|
+
readonly CLOSING: number
|
45
|
+
readonly CONNECTING: number
|
46
|
+
readonly OPEN: number
|
47
|
+
|
48
|
+
addEventListener<K extends keyof WebSocketEventMap>(
|
49
|
+
type: K,
|
50
|
+
listener: (this: WebSocket, ev: WebSocketEventMap[K]) => any,
|
51
|
+
options?: boolean | AddEventListenerOptions
|
52
|
+
): void
|
53
|
+
addEventListener(
|
54
|
+
type: string,
|
55
|
+
listener: EventListenerOrEventListenerObject,
|
56
|
+
options?: boolean | AddEventListenerOptions
|
57
|
+
): void
|
58
|
+
removeEventListener<K extends keyof WebSocketEventMap>(
|
59
|
+
type: K,
|
60
|
+
listener: (this: WebSocket, ev: WebSocketEventMap[K]) => any,
|
61
|
+
options?: boolean | EventListenerOptions
|
62
|
+
): void
|
63
|
+
removeEventListener(
|
64
|
+
type: string,
|
65
|
+
listener: EventListenerOrEventListenerObject,
|
66
|
+
options?: boolean | EventListenerOptions
|
67
|
+
): void
|
68
|
+
}
|
69
|
+
|
70
|
+
export declare const WebSocket: {
|
71
|
+
prototype: WebSocket
|
72
|
+
new (url: string | URL, protocols?: string | string[] | WebSocketInit): WebSocket
|
73
|
+
readonly CLOSED: number
|
74
|
+
readonly CLOSING: number
|
75
|
+
readonly CONNECTING: number
|
76
|
+
readonly OPEN: number
|
77
|
+
}
|
78
|
+
|
79
|
+
interface CloseEventInit extends EventInit {
|
80
|
+
code?: number
|
81
|
+
reason?: string
|
82
|
+
wasClean?: boolean
|
83
|
+
}
|
84
|
+
|
85
|
+
interface CloseEvent extends Event {
|
86
|
+
readonly code: number
|
87
|
+
readonly reason: string
|
88
|
+
readonly wasClean: boolean
|
89
|
+
}
|
90
|
+
|
91
|
+
export declare const CloseEvent: {
|
92
|
+
prototype: CloseEvent
|
93
|
+
new (type: string, eventInitDict?: CloseEventInit): CloseEvent
|
94
|
+
}
|
95
|
+
|
96
|
+
interface MessageEventInit<T = any> extends EventInit {
|
97
|
+
data?: T
|
98
|
+
lastEventId?: string
|
99
|
+
origin?: string
|
100
|
+
ports?: (typeof MessagePort)[]
|
101
|
+
source?: typeof MessagePort | null
|
102
|
+
}
|
103
|
+
|
104
|
+
interface MessageEvent<T = any> extends Event {
|
105
|
+
readonly data: T
|
106
|
+
readonly lastEventId: string
|
107
|
+
readonly origin: string
|
108
|
+
readonly ports: ReadonlyArray<typeof MessagePort>
|
109
|
+
readonly source: typeof MessagePort | null
|
110
|
+
initMessageEvent(
|
111
|
+
type: string,
|
112
|
+
bubbles?: boolean,
|
113
|
+
cancelable?: boolean,
|
114
|
+
data?: any,
|
115
|
+
origin?: string,
|
116
|
+
lastEventId?: string,
|
117
|
+
source?: typeof MessagePort | null,
|
118
|
+
ports?: (typeof MessagePort)[]
|
119
|
+
): void;
|
120
|
+
}
|
121
|
+
|
122
|
+
export declare const MessageEvent: {
|
123
|
+
prototype: MessageEvent
|
124
|
+
new<T>(type: string, eventInitDict?: MessageEventInit<T>): MessageEvent<T>
|
125
|
+
}
|
126
|
+
|
127
|
+
interface WebSocketInit {
|
128
|
+
protocols?: string | string[],
|
129
|
+
dispatcher?: Dispatcher,
|
130
|
+
headers?: HeadersInit
|
131
|
+
}
|
@@ -0,0 +1,197 @@
|
|
1
|
+
{
|
2
|
+
"name": "5.4",
|
3
|
+
"lockfileVersion": 3,
|
4
|
+
"requires": true,
|
5
|
+
"packages": {
|
6
|
+
"": {
|
7
|
+
"dependencies": {
|
8
|
+
"types-registry": "^0.1.685"
|
9
|
+
},
|
10
|
+
"devDependencies": {
|
11
|
+
"@types/domhandler": "^2.4.5",
|
12
|
+
"@types/htmlparser2": "^3.10.7",
|
13
|
+
"@types/node-fetch": "^2.6.11",
|
14
|
+
"@types/qs": "^6.9.15",
|
15
|
+
"@types/request": "^2.48.12"
|
16
|
+
}
|
17
|
+
},
|
18
|
+
"node_modules/@types/caseless": {
|
19
|
+
"version": "0.12.5",
|
20
|
+
"resolved": "https://registry.npmjs.org/@types/caseless/-/caseless-0.12.5.tgz",
|
21
|
+
"integrity": "sha512-hWtVTC2q7hc7xZ/RLbxapMvDMgUnDvKvMOpKal4DrMyfGBUfB1oKaZlIRr6mJL+If3bAP6sV/QneGzF6tJjZDg==",
|
22
|
+
"dev": true
|
23
|
+
},
|
24
|
+
"node_modules/@types/domhandler": {
|
25
|
+
"version": "2.4.5",
|
26
|
+
"resolved": "https://registry.npmjs.org/@types/domhandler/-/domhandler-2.4.5.tgz",
|
27
|
+
"integrity": "sha512-lANhC2grmFG1gBac/8sDAKdIXx+TzAdkJIAjEOSMA+qW3297ybACEbacJnG15aNYfrzDO6fdcoouokqAKsy6aQ==",
|
28
|
+
"dev": true
|
29
|
+
},
|
30
|
+
"node_modules/@types/domutils": {
|
31
|
+
"version": "1.7.8",
|
32
|
+
"resolved": "https://registry.npmjs.org/@types/domutils/-/domutils-1.7.8.tgz",
|
33
|
+
"integrity": "sha512-iZGboDV79ibrO3D625p9yD+VgmMDnyJocdIRJvu9Xz66R8SHfOY/XNgdjY5SFoFiLgILceVfSLt7IUhlk1Vhhg==",
|
34
|
+
"dev": true,
|
35
|
+
"dependencies": {
|
36
|
+
"@types/domhandler": "^2.4.0"
|
37
|
+
}
|
38
|
+
},
|
39
|
+
"node_modules/@types/htmlparser2": {
|
40
|
+
"version": "3.10.7",
|
41
|
+
"resolved": "https://registry.npmjs.org/@types/htmlparser2/-/htmlparser2-3.10.7.tgz",
|
42
|
+
"integrity": "sha512-ycBs4PNr9rY9XFFp4WkP+M1UcO49ahn0+9b24cmIY6KWy0w35rW0G8+JTTe9Rp6Wnyqn5SEHZrhCBMa0TIOxBw==",
|
43
|
+
"dev": true,
|
44
|
+
"dependencies": {
|
45
|
+
"@types/domhandler": "^2.4.3",
|
46
|
+
"@types/domutils": "*",
|
47
|
+
"@types/node": "*",
|
48
|
+
"domhandler": "^2.4.0"
|
49
|
+
}
|
50
|
+
},
|
51
|
+
"node_modules/@types/node": {
|
52
|
+
"version": "20.12.12",
|
53
|
+
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.12.12.tgz",
|
54
|
+
"integrity": "sha512-eWLDGF/FOSPtAvEqeRAQ4C8LSA7M1I7i0ky1I8U7kD1J5ITyW3AsRhQrKVoWf5pFKZ2kILsEGJhsI9r93PYnOw==",
|
55
|
+
"dev": true,
|
56
|
+
"dependencies": {
|
57
|
+
"undici-types": "~5.26.4"
|
58
|
+
}
|
59
|
+
},
|
60
|
+
"node_modules/@types/node-fetch": {
|
61
|
+
"version": "2.6.11",
|
62
|
+
"resolved": "https://registry.npmjs.org/@types/node-fetch/-/node-fetch-2.6.11.tgz",
|
63
|
+
"integrity": "sha512-24xFj9R5+rfQJLRyM56qh+wnVSYhyXC2tkoBndtY0U+vubqNsYXGjufB2nn8Q6gt0LrARwL6UBtMCSVCwl4B1g==",
|
64
|
+
"dev": true,
|
65
|
+
"dependencies": {
|
66
|
+
"@types/node": "*",
|
67
|
+
"form-data": "^4.0.0"
|
68
|
+
}
|
69
|
+
},
|
70
|
+
"node_modules/@types/qs": {
|
71
|
+
"version": "6.9.15",
|
72
|
+
"resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.9.15.tgz",
|
73
|
+
"integrity": "sha512-uXHQKES6DQKKCLh441Xv/dwxOq1TVS3JPUMlEqoEglvlhR6Mxnlew/Xq/LRVHpLyk7iK3zODe1qYHIMltO7XGg==",
|
74
|
+
"dev": true
|
75
|
+
},
|
76
|
+
"node_modules/@types/request": {
|
77
|
+
"version": "2.48.12",
|
78
|
+
"resolved": "https://registry.npmjs.org/@types/request/-/request-2.48.12.tgz",
|
79
|
+
"integrity": "sha512-G3sY+NpsA9jnwm0ixhAFQSJ3Q9JkpLZpJbI3GMv0mIAT0y3mRabYeINzal5WOChIiaTEGQYlHOKgkaM9EisWHw==",
|
80
|
+
"dev": true,
|
81
|
+
"dependencies": {
|
82
|
+
"@types/caseless": "*",
|
83
|
+
"@types/node": "*",
|
84
|
+
"@types/tough-cookie": "*",
|
85
|
+
"form-data": "^2.5.0"
|
86
|
+
}
|
87
|
+
},
|
88
|
+
"node_modules/@types/request/node_modules/form-data": {
|
89
|
+
"version": "2.5.1",
|
90
|
+
"resolved": "https://registry.npmjs.org/form-data/-/form-data-2.5.1.tgz",
|
91
|
+
"integrity": "sha512-m21N3WOmEEURgk6B9GLOE4RuWOFf28Lhh9qGYeNlGq4VDXUlJy2th2slBNU8Gp8EzloYZOibZJ7t5ecIrFSjVA==",
|
92
|
+
"dev": true,
|
93
|
+
"dependencies": {
|
94
|
+
"asynckit": "^0.4.0",
|
95
|
+
"combined-stream": "^1.0.6",
|
96
|
+
"mime-types": "^2.1.12"
|
97
|
+
},
|
98
|
+
"engines": {
|
99
|
+
"node": ">= 0.12"
|
100
|
+
}
|
101
|
+
},
|
102
|
+
"node_modules/@types/tough-cookie": {
|
103
|
+
"version": "4.0.5",
|
104
|
+
"resolved": "https://registry.npmjs.org/@types/tough-cookie/-/tough-cookie-4.0.5.tgz",
|
105
|
+
"integrity": "sha512-/Ad8+nIOV7Rl++6f1BdKxFSMgmoqEoYbHRpPcx3JEfv8VRsQe9Z4mCXeJBzxs7mbHY/XOZZuXlRNfhpVPbs6ZA==",
|
106
|
+
"dev": true
|
107
|
+
},
|
108
|
+
"node_modules/asynckit": {
|
109
|
+
"version": "0.4.0",
|
110
|
+
"resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
|
111
|
+
"integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==",
|
112
|
+
"dev": true
|
113
|
+
},
|
114
|
+
"node_modules/combined-stream": {
|
115
|
+
"version": "1.0.8",
|
116
|
+
"resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz",
|
117
|
+
"integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==",
|
118
|
+
"dev": true,
|
119
|
+
"dependencies": {
|
120
|
+
"delayed-stream": "~1.0.0"
|
121
|
+
},
|
122
|
+
"engines": {
|
123
|
+
"node": ">= 0.8"
|
124
|
+
}
|
125
|
+
},
|
126
|
+
"node_modules/delayed-stream": {
|
127
|
+
"version": "1.0.0",
|
128
|
+
"resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz",
|
129
|
+
"integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==",
|
130
|
+
"dev": true,
|
131
|
+
"engines": {
|
132
|
+
"node": ">=0.4.0"
|
133
|
+
}
|
134
|
+
},
|
135
|
+
"node_modules/domelementtype": {
|
136
|
+
"version": "1.3.1",
|
137
|
+
"resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-1.3.1.tgz",
|
138
|
+
"integrity": "sha512-BSKB+TSpMpFI/HOxCNr1O8aMOTZ8hT3pM3GQ0w/mWRmkhEDSFJkkyzz4XQsBV44BChwGkrDfMyjVD0eA2aFV3w==",
|
139
|
+
"dev": true
|
140
|
+
},
|
141
|
+
"node_modules/domhandler": {
|
142
|
+
"version": "2.4.2",
|
143
|
+
"resolved": "https://registry.npmjs.org/domhandler/-/domhandler-2.4.2.tgz",
|
144
|
+
"integrity": "sha512-JiK04h0Ht5u/80fdLMCEmV4zkNh2BcoMFBmZ/91WtYZ8qVXSKjiw7fXMgFPnHcSZgOo3XdinHvmnDUeMf5R4wA==",
|
145
|
+
"dev": true,
|
146
|
+
"dependencies": {
|
147
|
+
"domelementtype": "1"
|
148
|
+
}
|
149
|
+
},
|
150
|
+
"node_modules/form-data": {
|
151
|
+
"version": "4.0.0",
|
152
|
+
"resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz",
|
153
|
+
"integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==",
|
154
|
+
"dev": true,
|
155
|
+
"dependencies": {
|
156
|
+
"asynckit": "^0.4.0",
|
157
|
+
"combined-stream": "^1.0.8",
|
158
|
+
"mime-types": "^2.1.12"
|
159
|
+
},
|
160
|
+
"engines": {
|
161
|
+
"node": ">= 6"
|
162
|
+
}
|
163
|
+
},
|
164
|
+
"node_modules/mime-db": {
|
165
|
+
"version": "1.52.0",
|
166
|
+
"resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz",
|
167
|
+
"integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==",
|
168
|
+
"dev": true,
|
169
|
+
"engines": {
|
170
|
+
"node": ">= 0.6"
|
171
|
+
}
|
172
|
+
},
|
173
|
+
"node_modules/mime-types": {
|
174
|
+
"version": "2.1.35",
|
175
|
+
"resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz",
|
176
|
+
"integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==",
|
177
|
+
"dev": true,
|
178
|
+
"dependencies": {
|
179
|
+
"mime-db": "1.52.0"
|
180
|
+
},
|
181
|
+
"engines": {
|
182
|
+
"node": ">= 0.6"
|
183
|
+
}
|
184
|
+
},
|
185
|
+
"node_modules/types-registry": {
|
186
|
+
"version": "0.1.685",
|
187
|
+
"resolved": "https://registry.npmjs.org/types-registry/-/types-registry-0.1.685.tgz",
|
188
|
+
"integrity": "sha512-dC3Nqu/q2Ey8Jj/YV0plEub0oycMiu3VaAf+tf8X5uhtiRS4iF1BubY5cra1LIaKr+fTblxQvoVAYIPeVj1A9g=="
|
189
|
+
},
|
190
|
+
"node_modules/undici-types": {
|
191
|
+
"version": "5.26.5",
|
192
|
+
"resolved": "https://registry.npmjs.org/undici-types/-/undici-types-5.26.5.tgz",
|
193
|
+
"integrity": "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==",
|
194
|
+
"dev": true
|
195
|
+
}
|
196
|
+
}
|
197
|
+
}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"private":true,"dependencies":{"types-registry":"^0.1.685"},"devDependencies":{"@types/domhandler":"^2.4.5","@types/htmlparser2":"^3.10.7","@types/node-fetch":"^2.6.11","@types/qs":"^6.9.15","@types/request":"^2.48.12"}}
|
package/README.md
CHANGED
@@ -14,6 +14,55 @@
|
|
14
14
|
[![Socket Badge](https://socket.dev/api/badge/npm/package/rahad-media-downloader)](https://socket.dev/npm/package/rahad-media-downloader)
|
15
15
|
[![js dilvr](https://data.jsdelivr.com/v1/package/npm/rahad-media-downloader/badge)](https://www.jsdelivr.com/package/npm/rahad-media-downloader)
|
16
16
|
|
17
|
+
|
18
|
+
## All downloader :
|
19
|
+
## Instalation :
|
20
|
+
```bash
|
21
|
+
> npm i rahad-all-downloader
|
22
|
+
```
|
23
|
+
|
24
|
+
## Example (all downloader request)
|
25
|
+
```js
|
26
|
+
const { alldl } = require('rahad-all-downloader');
|
27
|
+
|
28
|
+
const videoUrl = ''; // Insert a supported URL from YouTube, Facebook, TikTok, Instagram, Twitter, Google Drive, or Capcut.
|
29
|
+
|
30
|
+
async function downloadVideo(url) {
|
31
|
+
try {
|
32
|
+
const result = await alldl(url);
|
33
|
+
console.log(result);// all response same
|
34
|
+
} catch (error) {
|
35
|
+
console.error('Error:', error.message);
|
36
|
+
}
|
37
|
+
}
|
38
|
+
|
39
|
+
downloadVideo(videoUrl);
|
40
|
+
```
|
41
|
+
## Output Example
|
42
|
+
```
|
43
|
+
{
|
44
|
+
"metadata": {
|
45
|
+
"Author": "Mohammad Rahad",
|
46
|
+
"message": "any problem please contact me",
|
47
|
+
"Facebook": "https://www.facebook.com/md.rahad.hosain18"
|
48
|
+
},
|
49
|
+
"data": {
|
50
|
+
"title": "ভালোবাসার মাঝে দুঃখ কষ্ট তো থাকবেই \nতার পরও শেষ টা সুন্দর হলেই হলো।",
|
51
|
+
"videoUrl": "https://video-ord5-2.xx.fbcdn.net/o1/v/t2/f2/m69/An-LG-mxljb9dfsGidTTV1zUJhcS4gRhTpsW9Vt6QkMswkLmCnvPdnJR9LaHWFkw3ggQdk1R5Tl1vl2Su8awWLIU.mp4?efg=eyJ2ZW5jb2RlX3RhZyI6Im9lcF9oZCJ9&_nc_ht=video-ord5-2.xx.fbcdn.net&_nc_cat=108&strext=1&vs=30fddamyiakXvrd0wnre0gCfiGYqOztiTw&oe=6665CA75&_nc_sid=1d576d&_nc_rid=438836236495732&_nc_store_type=1"
|
52
|
+
}
|
53
|
+
}
|
54
|
+
```
|
55
|
+
# Installation
|
56
|
+
|
57
|
+
## You can install
|
58
|
+
`rahad-all-downloader` using npm:
|
59
|
+
|
60
|
+
```bash
|
61
|
+
npm install rahad-all-downloader
|
62
|
+
```
|
63
|
+
|
64
|
+
## rahad-media-downloader
|
65
|
+
|
17
66
|
## Instalation :
|
18
67
|
```bash
|
19
68
|
> npm i rahad-media-downloader
|
@@ -320,5 +369,15 @@ This package is under development, and many exciting features are planned for fu
|
|
320
369
|
## Contributing
|
321
370
|
|
322
371
|
We welcome contributions! If you find any issues or have suggestions for improvement, feel free to open an issue or submit a pull request. If you want to contact me, check my [GitHub profile](https://github.com/MR-RAHAD-511).
|
323
|
-
|
324
|
-
|
372
|
+
# developer information
|
373
|
+
#### 𝗡𝗮𝗺𝗲 : 𝗠𝗼𝗵𝗮𝗺𝗺𝗮𝗱 𝗥𝗮𝗵𝗮𝗱
|
374
|
+
#### 𝗥𝗲𝗹𝗶𝗴𝗶𝗼𝗻 : (𝗜𝘀𝗹𝗮𝗺)
|
375
|
+
#### 𝗣𝗲𝗿𝗺𝗮𝗻𝗲𝗻𝘁 𝗔𝗱𝗱𝗿𝗲𝘀𝘀 : (𝗗𝗵𝗮𝗸𝗮)
|
376
|
+
#### 𝗖𝘂𝗿𝗿𝗲𝗻𝘁 𝗔𝗱𝗱𝗿𝗲𝘀𝘀 :𝗦𝗵𝗮𝗵𝗿𝗮𝘀𝘁𝗶 𝗖𝗵𝗮𝗻𝗱𝗽𝘂𝗿
|
377
|
+
#### 𝗚𝗲𝗻𝗱𝗲𝗿 : (𝗠𝗮𝗹𝗲)
|
378
|
+
#### 𝗔𝗴𝗲 : (𝟮𝟬)
|
379
|
+
#### 𝗥𝗲𝗹𝗮𝘁𝗶𝗼𝗻𝘀𝗵𝗶𝗽 : (𝗦𝗶𝗻𝗴𝗹𝗲)
|
380
|
+
#### 𝗚𝗺𝗮𝗶𝗹 : mdrahadhossain00@gmail.com
|
381
|
+
#### 𝗧𝗲𝗹𝗲𝗴𝗿𝗮𝗺 : t.me/rabbyhosainRahad
|
382
|
+
### [Facebook](https://www.facebook.com/md.rahad.hosain18)
|
383
|
+
`Copyright © 2024 Mohammad Rahad`
|