maxun-core 0.0.3 → 0.0.4
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.
|
@@ -192,7 +192,8 @@ function scrapableHeuristics(maxCountPerPage = 50, minArea = 20000, scrolls = 3,
|
|
|
192
192
|
return undefined;
|
|
193
193
|
switch (attribute) {
|
|
194
194
|
case 'href':
|
|
195
|
-
|
|
195
|
+
const relativeHref = elem.getAttribute('href'); // Get the href attribute
|
|
196
|
+
return relativeHref ? new URL(relativeHref, window.location.origin).href : null; // Convert to full URL
|
|
196
197
|
case 'src':
|
|
197
198
|
return elem.getAttribute('src');
|
|
198
199
|
case 'innerText':
|
|
@@ -38,7 +38,7 @@ export default class Concurrency {
|
|
|
38
38
|
/**
|
|
39
39
|
* Waits until there is no running nor waiting job. \
|
|
40
40
|
* If the concurrency manager is idle at the time of calling this function,
|
|
41
|
-
* it waits until at least one job is
|
|
41
|
+
* it waits until at least one job is completed (can be "presubscribed").
|
|
42
42
|
* @returns Promise, resolved after there is no running/waiting worker.
|
|
43
43
|
*/
|
|
44
44
|
waitForCompletion(): Promise<void>;
|
|
@@ -69,7 +69,7 @@ class Concurrency {
|
|
|
69
69
|
/**
|
|
70
70
|
* Waits until there is no running nor waiting job. \
|
|
71
71
|
* If the concurrency manager is idle at the time of calling this function,
|
|
72
|
-
* it waits until at least one job is
|
|
72
|
+
* it waits until at least one job is completed (can be "presubscribed").
|
|
73
73
|
* @returns Promise, resolved after there is no running/waiting worker.
|
|
74
74
|
*/
|
|
75
75
|
waitForCompletion() {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "maxun-core",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.4",
|
|
4
4
|
"description": "Core package for Maxun, responsible for data extraction",
|
|
5
5
|
"main": "build/index.js",
|
|
6
6
|
"typings": "build/index.d.ts",
|
|
@@ -20,7 +20,12 @@
|
|
|
20
20
|
"automation",
|
|
21
21
|
"workflow",
|
|
22
22
|
"data extraction",
|
|
23
|
-
"scraping"
|
|
23
|
+
"scraping",
|
|
24
|
+
"web scraper",
|
|
25
|
+
"web scraping",
|
|
26
|
+
"data scraping",
|
|
27
|
+
"no-code web scraper",
|
|
28
|
+
"no-code web scraping"
|
|
24
29
|
],
|
|
25
30
|
"author": "Maxun",
|
|
26
31
|
"license": "AGPL-3.0-or-later",
|