Skip to content

fix: use pathToFileURL for dynamic imports to support Windows paths - #49

Merged
Brooooooklyn merged 3 commits into
mainfrom
03-30-fix_use_pathtofileurl_for_dynamic_imports_to_support_windows_paths
Mar 31, 2026
Merged

Brooooooklyn merged 3 commits into
mainfrom
03-30-fix_use_pathtofileurl_for_dynamic_imports_to_support_windows_paths

Conversation

@shulaoda

@shulaoda shulaoda commented Mar 30, 2026 •

Copy link
Copy Markdown
Member

closes #48

Wrap the dynamic import() path arguments with pathToFileURL(path).href (from node:url) to produce valid file:///E:/... URLs.

@shulaoda
shulaoda force-pushed the 03-30-fix_use_pathtofileurl_for_dynamic_imports_to_support_windows_paths branch from ee15186 to ef35131 Compare March 30, 2026 11:27
@shulaoda
shulaoda marked this pull request as ready for review March 30, 2026 11:31
@shulaoda
shulaoda force-pushed the 03-30-fix_use_pathtofileurl_for_dynamic_imports_to_support_windows_paths branch from 585f793 to ef35131 Compare March 30, 2026 11:34
@shulaoda shulaoda closed this Mar 30, 2026
@shulaoda shulaoda reopened this Mar 30, 2026
@shulaoda
shulaoda force-pushed the 03-30-fix_use_pathtofileurl_for_dynamic_imports_to_support_windows_paths branch from ef35131 to a76581a Compare March 30, 2026 11:36
@Brooooooklyn
Brooooooklyn merged commit cba1bcd into main Mar 31, 2026
11 of 12 checks passed
@Brooooooklyn
Brooooooklyn deleted the 03-30-fix_use_pathtofileurl_for_dynamic_imports_to_support_windows_paths branch March 31, 2026 13:28
cpojer added a commit that referenced this pull request Sep 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Windows: "Received protocol 'e:'" error when running dynamic imports with absolute paths

2 participants