From 8fafe2011857a836cf1d8dd9530930d1d6205cf6 Mon Sep 17 00:00:00 2001 From: Kristóf Marussy Date: Fri, 31 Dec 2021 02:53:18 +0100 Subject: build: Use nodenext module resolution The renderer package still has to use node module resolution to be able to find MUI packages. --- packages/main/src/controllers/config.ts | 2 +- packages/main/src/services/impl/ConfigPersistenceServiceImpl.ts | 2 +- packages/renderer/tsconfig.json | 1 + tsconfig.json | 2 +- 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/main/src/controllers/config.ts b/packages/main/src/controllers/config.ts index ec23e8f..971f151 100644 --- a/packages/main/src/controllers/config.ts +++ b/packages/main/src/controllers/config.ts @@ -18,7 +18,7 @@ * SPDX-License-Identifier: AGPL-3.0-only */ -import debounce from 'lodash-es/debounce'; +import { debounce } from 'lodash-es'; import ms from 'ms'; import { applySnapshot, getSnapshot, onSnapshot } from 'mobx-state-tree'; diff --git a/packages/main/src/services/impl/ConfigPersistenceServiceImpl.ts b/packages/main/src/services/impl/ConfigPersistenceServiceImpl.ts index 22b7d65..65a51ba 100644 --- a/packages/main/src/services/impl/ConfigPersistenceServiceImpl.ts +++ b/packages/main/src/services/impl/ConfigPersistenceServiceImpl.ts @@ -21,7 +21,7 @@ import { watch } from 'fs'; import { readFile, stat, writeFile } from 'fs/promises'; import JSON5 from 'json5'; -import throttle from 'lodash-es/throttle'; +import { throttle} from 'lodash-es'; import { join } from 'path'; import type { ConfigPersistenceService, ReadConfigResult } from '../ConfigPersistenceService.js'; diff --git a/packages/renderer/tsconfig.json b/packages/renderer/tsconfig.json index 8746462..5cd8846 100644 --- a/packages/renderer/tsconfig.json +++ b/packages/renderer/tsconfig.json @@ -1,6 +1,7 @@ { "extends": "../../tsconfig.json", "compilerOptions": { + "moduleResolution": "node", "noEmit": true, "jsx": "react", "lib": [ diff --git a/tsconfig.json b/tsconfig.json index 255f334..e626876 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -2,7 +2,7 @@ "compilerOptions": { "module": "esnext", "target": "esnext", - "moduleResolution": "node", + "moduleResolution": "nodenext", "esModuleInterop": true, "allowSyntheticDefaultImports": true, "strict": true, -- cgit v1.2.3-54-g00ecf