Summary
When building with @eslint/config-inspector@1.5.0 for GitHub Pages project-subpath hosting, the generated HTML includes an importmap entry using root /_nuxt/..., which ignores --base and breaks runtime chunk loading.
1.4.2 with identical command works.
Repro command
npx -y @eslint/config-inspector@1.5.0 build \
--outDir temp/inspector-1.5.0 \
--base "/eslint-plugin-typefest/eslint-inspector/"
Expected
All runtime entry/chunk paths should respect --base, e.g.
/eslint-plugin-typefest/eslint-inspector/_nuxt/...
Actual (1.5.0 output)
Generated index.html includes:
<script type="importmap">{"imports":{"#entry":"/_nuxt/T86v09Lr.js"}}</script>
This causes browser requests to:
https://<host>/_nuxt/...
instead of subpath:
https://<host>/<repo>/eslint-inspector/_nuxt/...
Result: dynamic import failures / 404s on project-subpath deployments.
Comparison with 1.4.2
Using the same command with @eslint/config-inspector@1.4.2 works and does not emit this root importmap entry.
I built both versions with the same flags:
npx -y @eslint/config-inspector@1.4.2 build --outDir temp/inspector-ab-.../v1.4.2 --base "/eslint-plugin-typefest/eslint-inspector/"
npx -y @eslint/config-inspector@1.5.0 build --outDir temp/inspector-ab-.../v1.5.0 --base "/eslint-plugin-typefest/eslint-inspector/"
Both exited 0, both produced index.html.
Key difference in emitted HTML
1.4.2: no importmap entry forcing root /_nuxt entry.
1.5.0: emits:
<script type="importmap">{"imports":{"#entry":"/_nuxt/T86v09Lr.js"}}</script>
That absolute /_nuxt/... ignores your repo subpath and causes requests to:
https://nick2bad4u.github.io/_nuxt/...
instead of: https://nick2bad4u.github.io/eslint-plugin-typefest/eslint-inspector/_nuxt/...
Environment
- Hosting: GitHub Pages deployment
- Docusaurus site (all my docusaurus sites are affected when linking to eslint-config-inspector)
Summary
When building with
@eslint/config-inspector@1.5.0for GitHub Pages project-subpath hosting, the generated HTML includes an importmap entry using root/_nuxt/..., which ignores--baseand breaks runtime chunk loading.1.4.2with identical command works.Repro command
npx -y @eslint/config-inspector@1.5.0 build \ --outDir temp/inspector-1.5.0 \ --base "/eslint-plugin-typefest/eslint-inspector/"Expected
All runtime entry/chunk paths should respect
--base, e.g./eslint-plugin-typefest/eslint-inspector/_nuxt/...Actual (1.5.0 output)
Generated index.html includes:
This causes browser requests to:
https://<host>/_nuxt/...instead of subpath:
https://<host>/<repo>/eslint-inspector/_nuxt/...Result: dynamic import failures / 404s on project-subpath deployments.
Comparison with 1.4.2
Using the same command with
@eslint/config-inspector@1.4.2works and does not emit this root importmap entry.I built both versions with the same flags:
npx -y @eslint/config-inspector@1.4.2 build --outDir temp/inspector-ab-.../v1.4.2 --base "/eslint-plugin-typefest/eslint-inspector/"npx -y @eslint/config-inspector@1.5.0 build --outDir temp/inspector-ab-.../v1.5.0 --base "/eslint-plugin-typefest/eslint-inspector/"Both exited 0, both produced index.html.
Key difference in emitted HTML
1.4.2: no importmap entry forcing root /_nuxt entry.
1.5.0: emits:
<script type="importmap">{"imports":{"#entry":"/_nuxt/T86v09Lr.js"}}</script>
That absolute /_nuxt/... ignores your repo subpath and causes requests to:
https://nick2bad4u.github.io/_nuxt/...instead of:
https://nick2bad4u.github.io/eslint-plugin-typefest/eslint-inspector/_nuxt/...Environment