@browserless/goto 9.3.19 → 9.5.0
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/package.json +7 -7
- package/src/engine.bin +0 -0
- package/src/index.js +1 -28
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@browserless/goto",
|
|
3
3
|
"description": "Go to a page aborting unnecessary requests",
|
|
4
4
|
"homepage": "https://browserless.js.org/#/?id=gotopage-options",
|
|
5
|
-
"version": "9.
|
|
5
|
+
"version": "9.5.0",
|
|
6
6
|
"main": "src/index.js",
|
|
7
7
|
"author": {
|
|
8
8
|
"email": "hello@microlink.io",
|
|
@@ -29,17 +29,17 @@
|
|
|
29
29
|
"puppeteer"
|
|
30
30
|
],
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@browserless/devices": "^9.
|
|
33
|
-
"@cliqz/adblocker-puppeteer": "~1.23.
|
|
32
|
+
"@browserless/devices": "^9.4.1",
|
|
33
|
+
"@cliqz/adblocker-puppeteer": "~1.23.8",
|
|
34
34
|
"debug-logfmt": "~1.0.4",
|
|
35
|
-
"got": "~11.8.
|
|
36
|
-
"is-url-http": "~2.3.
|
|
35
|
+
"got": "~11.8.5",
|
|
36
|
+
"is-url-http": "~2.3.2",
|
|
37
37
|
"p-reflect": "~2.1.0",
|
|
38
38
|
"p-timeout": "~4.1.0",
|
|
39
39
|
"pretty-ms": "~7.0.1",
|
|
40
40
|
"shallow-equal": "~1.2.1",
|
|
41
41
|
"time-span": "~4.0.0",
|
|
42
|
-
"top-user-agents": "~1.0.
|
|
42
|
+
"top-user-agents": "~1.0.45",
|
|
43
43
|
"tough-cookie": "~4.0.0",
|
|
44
44
|
"unique-random-array": "~2.0.0"
|
|
45
45
|
},
|
|
@@ -68,5 +68,5 @@
|
|
|
68
68
|
"timeout": "2m",
|
|
69
69
|
"verbose": true
|
|
70
70
|
},
|
|
71
|
-
"gitHead": "
|
|
71
|
+
"gitHead": "2efe5725e9b370366303e2ffc3d377436689d221"
|
|
72
72
|
}
|
package/src/engine.bin
CHANGED
|
Binary file
|
package/src/index.js
CHANGED
|
@@ -92,10 +92,7 @@ const disableAnimations = `
|
|
|
92
92
|
}
|
|
93
93
|
`.trim()
|
|
94
94
|
|
|
95
|
-
const inject = async (
|
|
96
|
-
page,
|
|
97
|
-
{ timeout, mediaType, animations, hide, remove, modules, scripts, styles }
|
|
98
|
-
) => {
|
|
95
|
+
const inject = async (page, { timeout, mediaType, animations, modules, scripts, styles }) => {
|
|
99
96
|
const postPromises = []
|
|
100
97
|
|
|
101
98
|
if (mediaType) {
|
|
@@ -118,26 +115,6 @@ const inject = async (
|
|
|
118
115
|
)
|
|
119
116
|
}
|
|
120
117
|
|
|
121
|
-
if (hide) {
|
|
122
|
-
postPromises.push(
|
|
123
|
-
run({
|
|
124
|
-
fn: injectStyle(page, `${castArray(hide).join(', ')} { visibility: hidden !important; }`),
|
|
125
|
-
timeout,
|
|
126
|
-
debug: 'hide'
|
|
127
|
-
})
|
|
128
|
-
)
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
if (remove) {
|
|
132
|
-
postPromises.push(
|
|
133
|
-
run({
|
|
134
|
-
fn: injectStyle(page, `${castArray(remove).join(', ')} { display: none !important; }`),
|
|
135
|
-
timeout,
|
|
136
|
-
debug: 'remove'
|
|
137
|
-
})
|
|
138
|
-
)
|
|
139
|
-
}
|
|
140
|
-
|
|
141
118
|
if (modules) {
|
|
142
119
|
postPromises.push(
|
|
143
120
|
run({
|
|
@@ -215,12 +192,10 @@ module.exports = ({
|
|
|
215
192
|
click,
|
|
216
193
|
colorScheme,
|
|
217
194
|
headers = {},
|
|
218
|
-
hide,
|
|
219
195
|
html,
|
|
220
196
|
javascript = true,
|
|
221
197
|
mediaType,
|
|
222
198
|
modules,
|
|
223
|
-
remove,
|
|
224
199
|
scripts,
|
|
225
200
|
scroll,
|
|
226
201
|
styles,
|
|
@@ -384,8 +359,6 @@ module.exports = ({
|
|
|
384
359
|
timeout: actionTimeout,
|
|
385
360
|
mediaType,
|
|
386
361
|
animations,
|
|
387
|
-
hide,
|
|
388
|
-
remove,
|
|
389
362
|
modules,
|
|
390
363
|
scripts,
|
|
391
364
|
styles
|