Change package to ES module.

This commit is contained in:
Bauke 2023-03-26 14:32:57 +02:00
parent 6383e77609
commit 2e1c7edfa1
Signed by: Bauke
GPG Key ID: C1C0F29952BCF558
3 changed files with 9 additions and 13 deletions

View File

@ -1,5 +1,6 @@
{
"private": true,
"type": "module",
"scripts": {
"start": "vite build -m development --watch",
"start:chromium": "VITE_BROWSER=chromium pnpm start",
@ -37,14 +38,14 @@
"xo": "^0.53.1"
},
"ava": {
"extensions": [
"ts"
],
"extensions": {
"ts": "module"
},
"files": [
"tests/**/*.test.ts"
],
"require": [
"ts-node/register"
"nodeArguments": [
"--loader=ts-node/esm"
],
"snapshotDir": "tests/snapshots"
},
@ -65,7 +66,6 @@
"files": "tests/**/*.test.ts",
"rules": {
"@typescript-eslint/triple-slash-reference": "off",
"import/extensions": "off",
"no-await-in-loop": "off"
}
}

View File

@ -6,7 +6,7 @@ import {
dataMigrations,
deserializeQueue,
serializeQueue,
} from '../source/settings/migrations';
} from '../source/settings/migrations.js';
const queueItemSample: Queue.Item = {
added: new Date('2022-03-02T16:00:00Z'),

View File

@ -8,6 +8,7 @@
"moduleResolution": "Node",
"noEmit": true,
"outDir": "build",
"skipLibCheck": true,
"strict": true,
"target": "ESNext"
},
@ -15,10 +16,5 @@
"source/**/*.ts",
"tests/**/*.ts",
"vite.config.ts"
],
"ts-node": {
"compilerOptions": {
"module": "CommonJS"
}
}
]
}