@crawlee/templates 3.0.3-beta.19 → 3.0.3-beta.21
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 +1 -1
- package/templates/cheerio-js/src/main.js +2 -8
- package/templates/cheerio-ts/src/main.ts +2 -13
- package/templates/playwright-js/src/main.js +2 -8
- package/templates/playwright-ts/src/main.ts +2 -13
- package/templates/puppeteer-js/src/main.js +2 -8
- package/templates/puppeteer-ts/src/main.ts +2 -13
package/package.json
CHANGED
|
@@ -1,17 +1,11 @@
|
|
|
1
1
|
// For more information, see https://crawlee.dev/
|
|
2
|
-
import { CheerioCrawler,
|
|
2
|
+
import { CheerioCrawler, ProxyConfiguration } from 'crawlee';
|
|
3
3
|
import { router } from './routes.js';
|
|
4
4
|
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
if (debug) {
|
|
8
|
-
log.setLevel(log.LEVELS.DEBUG);
|
|
9
|
-
}
|
|
5
|
+
const startUrls = ['https://crawlee.dev'];
|
|
10
6
|
|
|
11
7
|
const crawler = new CheerioCrawler({
|
|
12
8
|
// proxyConfiguration: new ProxyConfiguration({ proxyUrls: ['...'] }),
|
|
13
|
-
// Be nice to the websites. Remove to unleash full power.
|
|
14
|
-
maxConcurrency: 50,
|
|
15
9
|
requestHandler: router,
|
|
16
10
|
});
|
|
17
11
|
|
|
@@ -1,22 +1,11 @@
|
|
|
1
1
|
// For more information, see https://crawlee.dev/
|
|
2
|
-
import { CheerioCrawler,
|
|
2
|
+
import { CheerioCrawler, ProxyConfiguration } from 'crawlee';
|
|
3
3
|
import { router } from './routes.js';
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
startUrls: string[];
|
|
7
|
-
debug?: boolean;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
const { startUrls = ['https://crawlee.dev'], debug } = await KeyValueStore.getInput<InputSchema>() ?? {};
|
|
11
|
-
|
|
12
|
-
if (debug) {
|
|
13
|
-
log.setLevel(log.LEVELS.DEBUG);
|
|
14
|
-
}
|
|
5
|
+
const startUrls = ['https://crawlee.dev'];
|
|
15
6
|
|
|
16
7
|
const crawler = new CheerioCrawler({
|
|
17
8
|
// proxyConfiguration: new ProxyConfiguration({ proxyUrls: ['...'] }),
|
|
18
|
-
// Be nice to the websites. Remove to unleash full power.
|
|
19
|
-
maxConcurrency: 50,
|
|
20
9
|
requestHandler: router,
|
|
21
10
|
});
|
|
22
11
|
|
|
@@ -1,17 +1,11 @@
|
|
|
1
1
|
// For more information, see https://crawlee.dev/
|
|
2
|
-
import {
|
|
2
|
+
import { PlaywrightCrawler, ProxyConfiguration } from 'crawlee';
|
|
3
3
|
import { router } from './routes.js';
|
|
4
4
|
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
if (debug) {
|
|
8
|
-
log.setLevel(log.LEVELS.DEBUG);
|
|
9
|
-
}
|
|
5
|
+
const startUrls = ['https://crawlee.dev'];
|
|
10
6
|
|
|
11
7
|
const crawler = new PlaywrightCrawler({
|
|
12
8
|
// proxyConfiguration: new ProxyConfiguration({ proxyUrls: ['...'] }),
|
|
13
|
-
// Be nice to the websites. Remove to unleash full power.
|
|
14
|
-
maxConcurrency: 50,
|
|
15
9
|
requestHandler: router,
|
|
16
10
|
});
|
|
17
11
|
|
|
@@ -1,22 +1,11 @@
|
|
|
1
1
|
// For more information, see https://crawlee.dev/
|
|
2
|
-
import {
|
|
2
|
+
import { PlaywrightCrawler, ProxyConfiguration } from 'crawlee';
|
|
3
3
|
import { router } from './routes.js';
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
startUrls: string[];
|
|
7
|
-
debug?: boolean;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
const { startUrls = ['https://crawlee.dev'], debug } = await KeyValueStore.getInput<InputSchema>() ?? {};
|
|
11
|
-
|
|
12
|
-
if (debug) {
|
|
13
|
-
log.setLevel(log.LEVELS.DEBUG);
|
|
14
|
-
}
|
|
5
|
+
const startUrls = ['https://crawlee.dev'];
|
|
15
6
|
|
|
16
7
|
const crawler = new PlaywrightCrawler({
|
|
17
8
|
// proxyConfiguration: new ProxyConfiguration({ proxyUrls: ['...'] }),
|
|
18
|
-
// Be nice to the websites. Remove to unleash full power.
|
|
19
|
-
maxConcurrency: 50,
|
|
20
9
|
requestHandler: router,
|
|
21
10
|
});
|
|
22
11
|
|
|
@@ -1,17 +1,11 @@
|
|
|
1
1
|
// For more information, see https://crawlee.dev/
|
|
2
|
-
import {
|
|
2
|
+
import { PuppeteerCrawler, ProxyConfiguration } from 'crawlee';
|
|
3
3
|
import { router } from './routes.js';
|
|
4
4
|
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
if (debug) {
|
|
8
|
-
log.setLevel(log.LEVELS.DEBUG);
|
|
9
|
-
}
|
|
5
|
+
const startUrls = ['https://crawlee.dev'];
|
|
10
6
|
|
|
11
7
|
const crawler = new PuppeteerCrawler({
|
|
12
8
|
// proxyConfiguration: new ProxyConfiguration({ proxyUrls: ['...'] }),
|
|
13
|
-
// Be nice to the websites. Remove to unleash full power.
|
|
14
|
-
maxConcurrency: 50,
|
|
15
9
|
requestHandler: router,
|
|
16
10
|
});
|
|
17
11
|
|
|
@@ -1,22 +1,11 @@
|
|
|
1
1
|
// For more information, see https://crawlee.dev/
|
|
2
|
-
import {
|
|
2
|
+
import { PuppeteerCrawler, log } from 'crawlee';
|
|
3
3
|
import { router } from './routes.js';
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
startUrls: string[];
|
|
7
|
-
debug?: boolean;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
const { startUrls = ['https://crawlee.dev'], debug } = await KeyValueStore.getInput<InputSchema>() ?? {};
|
|
11
|
-
|
|
12
|
-
if (debug) {
|
|
13
|
-
log.setLevel(log.LEVELS.DEBUG);
|
|
14
|
-
}
|
|
5
|
+
const startUrls = ['https://crawlee.dev'];
|
|
15
6
|
|
|
16
7
|
const crawler = new PuppeteerCrawler({
|
|
17
8
|
// proxyConfiguration: new ProxyConfiguration({ proxyUrls: ['...'] }),
|
|
18
|
-
// Be nice to the websites. Remove to unleash full power.
|
|
19
|
-
maxConcurrency: 50,
|
|
20
9
|
requestHandler: router,
|
|
21
10
|
});
|
|
22
11
|
|