vite-plugin-dynamic-import icon indicating copy to clipboard operation
vite-plugin-dynamic-import copied to clipboard

Dynamic import not working Windows

Open christoph-bessei opened this issue 2 years ago • 1 comments

In version 1.2.7 dynamic imports are working fine on Windows, but starting from 1.3.0 there's an issue (maybe a regression of #38?).

1.2.7

Dynamic imports are working on Windows, macOS & Ubuntu 22.04.

>= 1.3.0

Starting from 1.3.0 (same issue in 1.4.x & 1.5.0 I get the following error messages:

[vite-plugin-dynamic-import] no files matched: import(`@/components/icon/${path}/${upperFirstName}`)
   file: C:\Users\chris\Documents\demo\src\mixins\iconLoadMixin.js             
[vite-plugin-dynamic-import] no files matched: import(`@/components/cms/${type}`)     
   file: C:\Users\chris\Documents\demo\src\mixins\cmsJsonMixin.js

The same repository works just fine with macOS & Ubuntu 22.04, it it's probably related to the Windows path separator.

Please let me know if you need anything to reproduce the issue.

christoph-bessei avatar Dec 01 '23 19:12 christoph-bessei

Yep! I need a minimal reproduction repo here :)

yejimeiming avatar Dec 03 '23 12:12 yejimeiming