Crawlee—A web scraping and browser automation library for Node.js to build reliable crawlers. In JavaScript and TypeScript. Extract data for AI, LLMs, RAG, or GPTs. Download HTML, PDF, JPG, PNG, and other files from websites. Works with Puppeteer, Playwright, Cheerio, JSDOM, and raw HTTP. Both headful and headless mode. With proxy rotation.
TypeScript apifyautomationcrawlercrawlingheadlessheadless-chromejavascriptnodejsnpmplaywrightpuppeteerscraperscrapingtypescriptweb-crawlerweb-crawlingweb-scraping
chore: update TS eslint
Martin Adámek0d8ac78e3e99
diff --git a/package.json b/package.jsonindex c43de4424..5d4f80c78 100644--- a/package.json+++ b/package.json@@ -82,8 +82,8 @@"@types/stream-json": "^1.7.2","@types/tough-cookie": "^4.0.2","@types/yargs": "^17.0.26",- "@typescript-eslint/eslint-plugin": "^7.0.1",- "@typescript-eslint/parser": "^7.0.1",+ "@typescript-eslint/eslint-plugin": "^7.15.0",+ "@typescript-eslint/parser": "^7.15.0","@vitest/coverage-v8": "^1.0.0","apify": "*","basic-auth-parser": "^0.0.2",diff --git a/packages/core/src/enqueue_links/enqueue_links.ts b/packages/core/src/enqueue_links/enqueue_links.tsindex ecf1a14c4..5373dee69 100644--- a/packages/core/src/enqueue_links/enqueue_links.ts+++ b/packages/core/src/enqueue_links/enqueue_links.ts@@ -21,7 +21,7 @@ export interface EnqueueLinksOptions extends RequestQueueOperationOptions {limit?: number;/** An array of URLs to enqueue. */- urls?: Readonly<string[]>;+ urls?: readonly string[];/** A request queue to which the URLs will be enqueued. */requestQueue?: RequestProvider;@@ -60,7 +60,7 @@ export interface EnqueueLinksOptions extends RequestQueueOperationOptions {* If `globs` is an empty array or `undefined`, and `regexps` are also not defined, then the function* enqueues the links with the same subdomain.*/- globs?: Readonly<GlobInput[]>;+ globs?: readonly GlobInput[];/*** An array of glob pattern strings, regexp patterns or plain objects@@ -72,7 +72,7 @@ export interface EnqueueLinksOptions extends RequestQueueOperationOptions {* Glob matching is always case-insensitive.* If you need case-sensitive matching, provide a regexp.*/- exclude?: Readonly<(GlobInput | RegExpInput)[]>;+ exclude?: readonly (GlobInput | RegExpInput)[];/*** An array of regular expressions or plain objects@@ -84,7 +84,7 @@ export interface EnqueueLinksOptions extends RequestQueueOperationOptions {* If `regexps` is an empty array or `undefined`, and `globs` are also not defined, then the function* enqueues the links with the same subdomain.*/- regexps?: Readonly<RegExpInput[]>;+ regexps?: readonly RegExpInput[];/*** *NOTE:* In future versions of SDK the options will be removed.@@ -104,7 +104,7 @@ export interface EnqueueLinksOptions extends RequestQueueOperationOptions {** @deprecated prefer using `globs` or `regexps` instead*/- pseudoUrls?: Readonly<PseudoUrlInput[]>;+ pseudoUrls?: readonly PseudoUrlInput[];/*** Just before a new {@apilink Request} is constructed and enqueued to the {@apilink RequestQueue}, this function can be useddiff --git a/packages/core/src/enqueue_links/shared.ts b/packages/core/src/enqueue_links/shared.tsindex 970e62ad9..8edfc8fb9 100644--- a/packages/core/src/enqueue_links/shared.ts+++ b/packages/core/src/enqueue_links/shared.ts@@ -64,7 +64,7 @@ export function updateEnqueueLinksPatternCache(* to construct RegExps from PseudoUrl strings.* @ignore*/-export function constructRegExpObjectsFromPseudoUrls(pseudoUrls: Readonly<PseudoUrlInput[]>): RegExpObject[] {+export function constructRegExpObjectsFromPseudoUrls(pseudoUrls: readonly PseudoUrlInput[]): RegExpObject[] {return pseudoUrls.map((item) => {// Get pseudoUrl object from cache.let regexpObject = enqueueLinksPatternCache.get(item);@@ -88,7 +88,7 @@ export function constructRegExpObjectsFromPseudoUrls(pseudoUrls: Readonly<Pseudo* to construct Glob objects from Glob pattern strings.* @ignore*/-export function constructGlobObjectsFromGlobs(globs: Readonly<GlobInput[]>): GlobObject[] {+export function constructGlobObjectsFromGlobs(globs: readonly GlobInput[]): GlobObject[] {return globs.filter((glob) => {// Skip possibly nullish, empty strings@@ -139,7 +139,7 @@ export function validateGlobPattern(glob: string): string {* to check RegExps input and return valid RegExps.* @ignore*/-export function constructRegExpObjectsFromRegExps(regexps: Readonly<RegExpInput[]>): RegExpObject[] {+export function constructRegExpObjectsFromRegExps(regexps: readonly RegExpInput[]): RegExpObject[] {return regexps.map((item) => {// Get regexp object from cache.let regexpObject = enqueueLinksPatternCache.get(item);diff --git a/yarn.lock b/yarn.lockindex 123d52015..002db43e4 100644--- a/yarn.lock+++ b/yarn.lock@@ -763,8 +763,8 @@ __metadata:"@types/stream-json": "npm:^1.7.2""@types/tough-cookie": "npm:^4.0.2""@types/yargs": "npm:^17.0.26"- "@typescript-eslint/eslint-plugin": "npm:^7.0.1"- "@typescript-eslint/parser": "npm:^7.0.1"+ "@typescript-eslint/eslint-plugin": "npm:^7.15.0"+ "@typescript-eslint/parser": "npm:^7.15.0""@vitest/coverage-v8": "npm:^1.0.0"apify: "npm:*"basic-auth-parser: "npm:^0.0.2"@@ -2423,15 +2423,15 @@ __metadata:languageName: nodelinkType: hard-"@typescript-eslint/eslint-plugin@npm:^7.0.1":- version: 7.14.1- resolution: "@typescript-eslint/eslint-plugin@npm:7.14.1"+"@typescript-eslint/eslint-plugin@npm:^7.15.0":+ version: 7.15.0+ resolution: "@typescript-eslint/eslint-plugin@npm:7.15.0"dependencies:"@eslint-community/regexpp": "npm:^4.10.0"- "@typescript-eslint/scope-manager": "npm:7.14.1"- "@typescript-eslint/type-utils": "npm:7.14.1"- "@typescript-eslint/utils": "npm:7.14.1"- "@typescript-eslint/visitor-keys": "npm:7.14.1"+ "@typescript-eslint/scope-manager": "npm:7.15.0"+ "@typescript-eslint/type-utils": "npm:7.15.0"+ "@typescript-eslint/utils": "npm:7.15.0"+ "@typescript-eslint/visitor-keys": "npm:7.15.0"graphemer: "npm:^1.4.0"ignore: "npm:^5.3.1"natural-compare: "npm:^1.4.0"@@ -2442,44 +2442,44 @@ __metadata:peerDependenciesMeta:typescript:optional: true- checksum: 10c0/7c2b9b98a38d78326b0ff7348fe001203eda10817ca7834a7a01f492ae7c2508469bbafaa933208d6459f8ff6685277685983cf6f6843e556a6ab2aa5c05080c+ checksum: 10c0/7ed4ef8355cb60f02ed603673ef749928a001931c534960d1f3f9f9b8092f4abd7ec1e80a33b4c38efb6e8e66c902583bd56a4c4d6ccbd870677a40680a7d1f5languageName: nodelinkType: hard-"@typescript-eslint/parser@npm:^7.0.1":- version: 7.14.1- resolution: "@typescript-eslint/parser@npm:7.14.1"+"@typescript-eslint/parser@npm:^7.15.0":+ version: 7.15.0+ resolution: "@typescript-eslint/parser@npm:7.15.0"dependencies:- "@typescript-eslint/scope-manager": "npm:7.14.1"- "@typescript-eslint/types": "npm:7.14.1"- "@typescript-eslint/typescript-estree": "npm:7.14.1"- "@typescript-eslint/visitor-keys": "npm:7.14.1"+ "@typescript-eslint/scope-manager": "npm:7.15.0"+ "@typescript-eslint/types": "npm:7.15.0"+ "@typescript-eslint/typescript-estree": "npm:7.15.0"+ "@typescript-eslint/visitor-keys": "npm:7.15.0"debug: "npm:^4.3.4"peerDependencies:eslint: ^8.56.0peerDependenciesMeta:typescript:optional: true- checksum: 10c0/db3169d4852685cfb27db741c557f58a3e52104bfacc7621beb7c94ec36ac2a08d4e410ac86745db52f482fbfc87e99fa0a26c1d7a10d37a215cce85e1661f0e+ checksum: 10c0/8dcad9b84e2cbf89afea97ee7f690f91b487eed21d01997126f98cb7dd56d3b6c98c7ecbdbeda35904af521c4ed746c47887e908f8a1e2148d47c05b491d7b9dlanguageName: nodelinkType: hard-"@typescript-eslint/scope-manager@npm:7.14.1":- version: 7.14.1- resolution: "@typescript-eslint/scope-manager@npm:7.14.1"+"@typescript-eslint/scope-manager@npm:7.15.0":+ version: 7.15.0+ resolution: "@typescript-eslint/scope-manager@npm:7.15.0"dependencies:- "@typescript-eslint/types": "npm:7.14.1"- "@typescript-eslint/visitor-keys": "npm:7.14.1"- checksum: 10c0/f8c05a0d6f8de4cc19b90a4da308817c66e53f36f7ec48f6cc23e93c7399bc418643d8135933aaf5fc013199cbef0e1ea4223f5147db5ca401b239eaf087011e+ "@typescript-eslint/types": "npm:7.15.0"+ "@typescript-eslint/visitor-keys": "npm:7.15.0"+ checksum: 10c0/781ec31a07ab7f0bdfb07dd271ef6553aa98f8492f1b3a67c65d178c94d590f4fd2e0916450f2446f1da2fbe007f3454c360ccb25f4d69612f782eb499f400ablanguageName: nodelinkType: hard-"@typescript-eslint/type-utils@npm:7.14.1":- version: 7.14.1- resolution: "@typescript-eslint/type-utils@npm:7.14.1"+"@typescript-eslint/type-utils@npm:7.15.0":+ version: 7.15.0+ resolution: "@typescript-eslint/type-utils@npm:7.15.0"dependencies:- "@typescript-eslint/typescript-estree": "npm:7.14.1"- "@typescript-eslint/utils": "npm:7.14.1"+ "@typescript-eslint/typescript-estree": "npm:7.15.0"+ "@typescript-eslint/utils": "npm:7.15.0"debug: "npm:^4.3.4"ts-api-utils: "npm:^1.3.0"peerDependencies:@@ -2487,23 +2487,23 @@ __metadata:peerDependenciesMeta:typescript:optional: true- checksum: 10c0/bd1c4a8db6273e24156fb10da2cbeb52b4eb03f819da193d4b6bd5a95db3b5524c6fe00d088308d8855b9ae60a3b82afa3a06e89982a09a8573561da960758fd+ checksum: 10c0/06189eb05d741f05977bbc029c6ac46edd566e0136f2f2c22429fd5f2be1224e2d9135b7021bc686871bfaec9c05a5c9990a321762d3abd06e457486956326balanguageName: nodelinkType: hard-"@typescript-eslint/types@npm:7.14.1":- version: 7.14.1- resolution: "@typescript-eslint/types@npm:7.14.1"- checksum: 10c0/5b7bda83c47a9b386482e63447c6b0ed7bd4e82eb43f11a180c6e2f3d2e7a2828f57bcbed82196ad761c49e363cccf4c81a89f1fc976e9f5f0a79dcc928fa2d2+"@typescript-eslint/types@npm:7.15.0":+ version: 7.15.0+ resolution: "@typescript-eslint/types@npm:7.15.0"+ checksum: 10c0/935387b21d9fdff65de86f6350cdda1f0614e269324f3a4f0a2ca1b0d72ef4b1d40c7de2f3a20a6f8c83edca6507bfbac3168c860625859e59fc455c80392bedlanguageName: nodelinkType: hard-"@typescript-eslint/typescript-estree@npm:7.14.1":- version: 7.14.1- resolution: "@typescript-eslint/typescript-estree@npm:7.14.1"+"@typescript-eslint/typescript-estree@npm:7.15.0":+ version: 7.15.0+ resolution: "@typescript-eslint/typescript-estree@npm:7.15.0"dependencies:- "@typescript-eslint/types": "npm:7.14.1"- "@typescript-eslint/visitor-keys": "npm:7.14.1"+ "@typescript-eslint/types": "npm:7.15.0"+ "@typescript-eslint/visitor-keys": "npm:7.15.0"debug: "npm:^4.3.4"globby: "npm:^11.1.0"is-glob: "npm:^4.0.3"@@ -2513,31 +2513,31 @@ __metadata:peerDependenciesMeta:typescript:optional: true- checksum: 10c0/a8da9bcc4de3334a225424946abd99374de05c42098455419224bc0f46bb1b66115f8bd6ae268461294b90943ed4a407bcd255c0fa60eb76ba4cdc5fc7c20855+ checksum: 10c0/0d6e61cb36c4612147ceea796c2bdbb65fca59170d9d768cff314146c5564253a058cbcb9e251722cd76c92a90c257e1210a69f8d4377c8002f211c574d18d24languageName: nodelinkType: hard-"@typescript-eslint/utils@npm:7.14.1":- version: 7.14.1- resolution: "@typescript-eslint/utils@npm:7.14.1"+"@typescript-eslint/utils@npm:7.15.0":+ version: 7.15.0+ resolution: "@typescript-eslint/utils@npm:7.15.0"dependencies:"@eslint-community/eslint-utils": "npm:^4.4.0"- "@typescript-eslint/scope-manager": "npm:7.14.1"- "@typescript-eslint/types": "npm:7.14.1"- "@typescript-eslint/typescript-estree": "npm:7.14.1"+ "@typescript-eslint/scope-manager": "npm:7.15.0"+ "@typescript-eslint/types": "npm:7.15.0"+ "@typescript-eslint/typescript-estree": "npm:7.15.0"peerDependencies:eslint: ^8.56.0- checksum: 10c0/c7f635a3c2c6c085e1d51a52088e55cad9d7e1257b1f60378e5eeb6eb0871db027d42747e9ef60a2f557cf9dd68b2ce014d488d795db8f771506290b164b0e5a+ checksum: 10c0/26aced17976cee0aa39a79201f68b384bbce1dc96e1c70d0e5f790e1e5655b1b1ddb2afd9eaf3fce9a48c0fb69daecd37a99fdbcdbf1cb58c65ae89ecac88a2clanguageName: nodelinkType: hard-"@typescript-eslint/visitor-keys@npm:7.14.1":- version: 7.14.1- resolution: "@typescript-eslint/visitor-keys@npm:7.14.1"+"@typescript-eslint/visitor-keys@npm:7.15.0":+ version: 7.15.0+ resolution: "@typescript-eslint/visitor-keys@npm:7.15.0"dependencies:- "@typescript-eslint/types": "npm:7.14.1"+ "@typescript-eslint/types": "npm:7.15.0"eslint-visitor-keys: "npm:^3.4.3"- checksum: 10c0/39ac489990fcfdcee442f27658431a0eb44ccf694f701a45df2a108c47cea9582e0955bff0d449047549149385f72895a5d7e6c1622ece1fe32594b7cecb85f3+ checksum: 10c0/7509f01c8cd2126a38213bc735a77aa7e976340af0d664be5b2ccd01b8211724b2ea129e33bfd32fe5feac848b7b68ca55bb533f6ccfeec1d2f26a91240489b9languageName: nodelinkType: hard