From b76fa8cb1df6bd1eae2ea6175937fe03d0e50ae0 Mon Sep 17 00:00:00 2001 From: LiFengbao Date: Tue, 12 Jul 2022 11:23:36 +0800 Subject: [PATCH 1/2] fix: resolveFile method will raise an exception if the filename is resolved twice --- lib/less/aliases-plugin.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/less/aliases-plugin.ts b/lib/less/aliases-plugin.ts index e887a11..48b5ddf 100644 --- a/lib/less/aliases-plugin.ts +++ b/lib/less/aliases-plugin.ts @@ -75,6 +75,9 @@ export class LessAliasesPlugin { } } + if (!isHited) { + return filename; + } if (isHited && !resolvedPath) { throw new Error(`Invalid @import: ${filename}`); } From 64f77922107d2127c3af6ba6389102c825737edf Mon Sep 17 00:00:00 2001 From: LiFengbao Date: Tue, 12 Jul 2022 11:23:36 +0800 Subject: [PATCH 2/2] chore: bump version --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 2a65eb9..fafe362 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@qiniu/typed-less-modules", - "version": "0.1.2", + "version": "0.1.2-1", "description": "TypeScript type definition generator for LESS CSS Modules", "main": "index.js", "license": "Apache",