metascraper-instagram 5.31.1 → 5.31.2
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/index.js +5 -3
- package/package.json +4 -5
package/index.js
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
'use strict'
|
|
2
2
|
|
|
3
|
-
const { memoizeOne,
|
|
4
|
-
const { getDomainWithoutSuffix } = require('tldts')
|
|
3
|
+
const { composeRule, memoizeOne, parseUrl } = require('@metascraper/helpers')
|
|
5
4
|
const { JSDOM, VirtualConsole } = require('jsdom')
|
|
6
5
|
const { keys, first, get } = require('lodash')
|
|
7
6
|
|
|
8
|
-
const test = memoizeOne(
|
|
7
|
+
const test = memoizeOne(
|
|
8
|
+
url => parseUrl(url).domainWithoutSuffix === 'instagram'
|
|
9
|
+
)
|
|
9
10
|
|
|
10
11
|
const getPage = sharedData => first(keys(get(sharedData, 'entry_data')))
|
|
11
12
|
|
|
@@ -64,6 +65,7 @@ const extractData = memoizeOne((url, $) => {
|
|
|
64
65
|
}
|
|
65
66
|
}
|
|
66
67
|
})
|
|
68
|
+
|
|
67
69
|
const getData = composeRule(($, url) => extractData(url, $))
|
|
68
70
|
|
|
69
71
|
module.exports = () => {
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "metascraper-instagram",
|
|
3
3
|
"description": "Metascraper integration for Instagram",
|
|
4
4
|
"homepage": "https://nicedoc.io/microlinkhq/metascraper/packages/metascraper-instagram",
|
|
5
|
-
"version": "5.31.
|
|
5
|
+
"version": "5.31.2",
|
|
6
6
|
"main": "index.js",
|
|
7
7
|
"author": {
|
|
8
8
|
"email": "hello@microlink.io",
|
|
@@ -22,10 +22,9 @@
|
|
|
22
22
|
"telegram"
|
|
23
23
|
],
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@metascraper/helpers": "^5.31.
|
|
25
|
+
"@metascraper/helpers": "^5.31.2",
|
|
26
26
|
"jsdom": "~20.0.0",
|
|
27
|
-
"lodash": "~4.17.21"
|
|
28
|
-
"tldts": "~5.7.92"
|
|
27
|
+
"lodash": "~4.17.21"
|
|
29
28
|
},
|
|
30
29
|
"devDependencies": {
|
|
31
30
|
"ava": "latest"
|
|
@@ -40,5 +39,5 @@
|
|
|
40
39
|
"test": "NODE_PATH=.. TZ=UTC ava --timeout 15s"
|
|
41
40
|
},
|
|
42
41
|
"license": "MIT",
|
|
43
|
-
"gitHead": "
|
|
42
|
+
"gitHead": "74d95629233e8bd81c0018e388b67ce663aac384"
|
|
44
43
|
}
|