From 2cc6f3cdfb1b7f99b3bb97f2f9f005f69506d8ef Mon Sep 17 00:00:00 2001 From: Kanad Gupta Date: Mon, 6 Nov 2023 10:16:59 -0600 Subject: [PATCH] refactor: specify ts-node ESM flag in tsconfig --- package.json | 2 +- tsconfig.json | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index b91f2e4bd..8dbb6312a 100644 --- a/package.json +++ b/package.json @@ -107,7 +107,7 @@ "scripts": { "build": "tsc", "build:exe": "npm run build && rollup -c && pkg dist/rollup-output.cjs --target host --output exe/rdme", - "debug": "ts-node --esm src/cli.ts", + "debug": "ts-node src/cli.ts", "lint": "alex . && knip && npm run lint:ts && npm run prettier && npm run schemas:check", "lint:ts": "eslint . --ext .js,.ts", "prebuild": "rm -rf dist/", diff --git a/tsconfig.json b/tsconfig.json index 26b1ec69c..ce704f1e5 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -12,5 +12,8 @@ "target": "ES2022", "useUnknownInCatchVariables": false }, - "include": ["./src/**/*"] + "include": ["./src/**/*"], + "ts-node": { + "esm": true + } }