metascraper-youtube 5.29.3 → 5.29.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +11 -8
- package/index.js +3 -3
- package/package.json +13 -10
package/README.md
CHANGED
|
@@ -1,9 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
> Metascraper integration with YouTube
|
|
1
|
+
<div align="center">
|
|
2
|
+
<br>
|
|
3
|
+
<img style="width: 500px; margin:3rem 0 1.5rem;" src="https://metascraper.js.org/static/logo-banner.png" alt="metascraper">
|
|
4
|
+
<br>
|
|
5
|
+
<br>
|
|
6
|
+
<p align="center"><strong>metascraper-youtube</strong>: Metascraper integration with YouTube.</p>
|
|
7
|
+
<p align="center">See our <a href="https://metascraper.js.org" target='_blank' rel='noopener noreferrer'>website</a> for more information.</p>
|
|
8
|
+
<br>
|
|
9
|
+
</div>
|
|
7
10
|
|
|
8
11
|
## Install
|
|
9
12
|
|
|
@@ -21,7 +24,7 @@ Any option provided here will passed to [got#options](https://github.com/sindres
|
|
|
21
24
|
|
|
22
25
|
## License
|
|
23
26
|
|
|
24
|
-
**metascraper-youtube** © [Microlink](https://microlink.io),
|
|
27
|
+
**metascraper-youtube** © [Microlink](https://microlink.io), released under the [MIT](https://github.com/microlinkhq/metascraper/blob/master/LICENSE.md) License.<br>
|
|
25
28
|
Authored and maintained by [Microlink](https://microlink.io) with help from [contributors](https://github.com/microlinkhq/metascraper/contributors).
|
|
26
29
|
|
|
27
|
-
> [microlink.io](https://microlink.io) · GitHub [
|
|
30
|
+
> [microlink.io](https://microlink.io) · GitHub [microlinkhq](https://github.com/microlinkhq) · Twitter [@microlinkhq](https://twitter.com/microlinkhq)
|
package/index.js
CHANGED
|
@@ -36,7 +36,7 @@ const toDescription = toRule(description)
|
|
|
36
36
|
|
|
37
37
|
const getVideoInfo = memoizeOne(getVideoId)
|
|
38
38
|
|
|
39
|
-
const
|
|
39
|
+
const test = memoizeOne(url => getVideoInfo(url).service === 'youtube')
|
|
40
40
|
|
|
41
41
|
module.exports = ({ gotOpts } = {}) => {
|
|
42
42
|
const rules = {
|
|
@@ -55,9 +55,9 @@ module.exports = ({ gotOpts } = {}) => {
|
|
|
55
55
|
]
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
-
rules.test = ({ url }) =>
|
|
58
|
+
rules.test = ({ url }) => test(url)
|
|
59
59
|
|
|
60
60
|
return rules
|
|
61
61
|
}
|
|
62
62
|
|
|
63
|
-
module.exports.
|
|
63
|
+
module.exports.test = test
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "metascraper-youtube",
|
|
3
3
|
"description": "Metascraper integration with YouTube",
|
|
4
4
|
"homepage": "https://nicedoc.io/microlinkhq/metascraper/packages/metascraper-youtube",
|
|
5
|
-
"version": "5.29.
|
|
5
|
+
"version": "5.29.7",
|
|
6
6
|
"main": "index.js",
|
|
7
7
|
"author": {
|
|
8
8
|
"email": "hello@microlink.io",
|
|
@@ -23,16 +23,13 @@
|
|
|
23
23
|
"youtube"
|
|
24
24
|
],
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@metascraper/helpers": "^5.29.
|
|
27
|
-
"get-video-id": "~3.
|
|
26
|
+
"@metascraper/helpers": "^5.29.7",
|
|
27
|
+
"get-video-id": "~3.6.4",
|
|
28
28
|
"p-locate": "~5.0.0",
|
|
29
|
-
"reachable-url": "~1.6.
|
|
29
|
+
"reachable-url": "~1.6.11"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
|
-
"
|
|
33
|
-
"mocha": "latest",
|
|
34
|
-
"should": "latest",
|
|
35
|
-
"snap-shot": "latest"
|
|
32
|
+
"ava": "latest"
|
|
36
33
|
},
|
|
37
34
|
"engines": {
|
|
38
35
|
"node": ">= 12"
|
|
@@ -41,8 +38,14 @@
|
|
|
41
38
|
"index.js"
|
|
42
39
|
],
|
|
43
40
|
"scripts": {
|
|
44
|
-
"test": "NODE_PATH=.. TZ=UTC
|
|
41
|
+
"test": "NODE_PATH=.. TZ=UTC ava --timeout 15s"
|
|
45
42
|
},
|
|
46
43
|
"license": "MIT",
|
|
47
|
-
"
|
|
44
|
+
"ava": {
|
|
45
|
+
"files": [
|
|
46
|
+
"test/**/*.js",
|
|
47
|
+
"!test/helpers.js"
|
|
48
|
+
]
|
|
49
|
+
},
|
|
50
|
+
"gitHead": "78434709c910cca5d8df3871c0b06131cce5df45"
|
|
48
51
|
}
|