Skip to content

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.

refactor: use node loader instead of `ts-node-esm` in templates

Martin Adámek52b47d2746fa
diff --git a/packages/templates/templates/cheerio-ts/package.json b/packages/templates/templates/cheerio-ts/package.json
index 1944a3ddf..b9fdb1bae 100644
--- a/packages/templates/templates/cheerio-ts/package.json
+++ b/packages/templates/templates/cheerio-ts/package.json
@@ -15,7 +15,7 @@
"scripts": {
"start": "npm run start:dev",
"start:prod": "node dist/main.js",
- "start:dev": "ts-node-esm -T src/main.ts",
+ "start:dev": "node --no-warnings=ExperimentalWarning --loader ts-node/esm/transpile-only src/main.ts",
"build": "tsc",
"test": "echo \"Error: oops, the actor has no tests yet, sad!\" && exit 1"
},
diff --git a/packages/templates/templates/getting-started-ts/package.json b/packages/templates/templates/getting-started-ts/package.json
index f2f3c8a04..f90a11cb5 100644
--- a/packages/templates/templates/getting-started-ts/package.json
+++ b/packages/templates/templates/getting-started-ts/package.json
@@ -16,7 +16,7 @@
"scripts": {
"start": "npm run start:dev",
"start:prod": "node dist/main.js",
- "start:dev": "ts-node-esm -T src/main.ts",
+ "start:dev": "node --no-warnings=ExperimentalWarning --loader ts-node/esm/transpile-only src/main.ts",
"build": "tsc",
"test": "echo \"Error: oops, the actor has no tests yet, sad!\" && exit 1"
},
diff --git a/packages/templates/templates/playwright-ts/package.json b/packages/templates/templates/playwright-ts/package.json
index 5c2dd4add..2c4ed013e 100644
--- a/packages/templates/templates/playwright-ts/package.json
+++ b/packages/templates/templates/playwright-ts/package.json
@@ -16,7 +16,7 @@
"scripts": {
"start": "npm run start:dev",
"start:prod": "node dist/main.js",
- "start:dev": "ts-node-esm -T src/main.ts",
+ "start:dev": "node --no-warnings=ExperimentalWarning --loader ts-node/esm/transpile-only src/main.ts",
"build": "tsc",
"test": "echo \"Error: oops, the actor has no tests yet, sad!\" && exit 1"
},
diff --git a/packages/templates/templates/puppeteer-ts/package.json b/packages/templates/templates/puppeteer-ts/package.json
index e126339a0..46eb6bc78 100644
--- a/packages/templates/templates/puppeteer-ts/package.json
+++ b/packages/templates/templates/puppeteer-ts/package.json
@@ -16,7 +16,7 @@
"scripts": {
"start": "npm run start:dev",
"start:prod": "node dist/main.js",
- "start:dev": "ts-node-esm -T src/main.ts",
+ "start:dev": "node --no-warnings=ExperimentalWarning --loader ts-node/esm/transpile-only src/main.ts",
"build": "tsc",
"test": "echo \"Error: oops, the actor has no tests yet, sad!\" && exit 1"
},