From f1791dd0224ba8b1fbb4fe358f60d1cece0656d5 Mon Sep 17 00:00:00 2001 From: hai-x Date: Sat, 11 Jan 2025 14:39:11 +0800 Subject: [PATCH 1/2] fix: add more detailed error messages --- src/instances.ts | 2 +- src/servicesHost.ts | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/instances.ts b/src/instances.ts index 6be876d68..376ecd73a 100644 --- a/src/instances.ts +++ b/src/instances.ts @@ -375,7 +375,7 @@ export function initializeInstance( } else { if (!loader._compiler!.hooks) { throw new Error( - "You may be using an old version of webpack; please check you're using at least version 4" + "You may be using an old version of webpack; please check you're using at least version 4. Or you should set `transpileOnly` or `happyPackMode` to true when using with `thread-loader`." ); } diff --git a/src/servicesHost.ts b/src/servicesHost.ts index 1445fd873..ff1997c1f 100644 --- a/src/servicesHost.ts +++ b/src/servicesHost.ts @@ -382,7 +382,6 @@ function createWatchFactory( } return result; } - ``; function invokeRecursiveDirectoryWatcher( directory: string, From f6c15a78e931c094102e35b77eab246aee27a617 Mon Sep 17 00:00:00 2001 From: hai-x Date: Sat, 11 Jan 2025 16:53:44 +0800 Subject: [PATCH 2/2] chore: meta --- CHANGELOG.md | 3 +++ package.json | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8f2f23014..278ad8efd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,8 @@ # Changelog +## 9.5.2 +* [fix: add more detailed error messages](https://github.com/TypeStrong/ts-loader/pull/1665) - thanks @hai-x + ## 9.5.1 * [fix: inputSourceMap can be null](https://github.com/TypeStrong/ts-loader/pull/1639) [#1638] - thanks @johnnyreilly and @michaeltford diff --git a/package.json b/package.json index b8655a2fd..db727528b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ts-loader", - "version": "9.5.1", + "version": "9.5.2", "description": "TypeScript loader for webpack", "main": "index.js", "types": "dist",