Skip to content

fix(feed-directory): bundle catalog client script in Astro build - #1242

Merged
gildesmarais merged 1 commit into
mainfrom
fix/feed-directory-catalog-script
Aug 22, 2026
Merged

fix(feed-directory): bundle catalog client script in Astro build#1242
gildesmarais merged 1 commit into
mainfrom
fix/feed-directory-catalog-script

Conversation

@gildesmarais

Copy link
Copy Markdown
Member

What changed

  • src/components/FeedDirectory.astro loads feed-directory.js via an inline Astro <script> import instead of <script src="./feed-directory.js">.
  • Production build now emits /_astro/FeedDirectory.astro_astro_type_script_index_0_lang.*.js, which includes the catalog client and GET /api/v1/configs fetch.

Why

The feed directory shipped a relative ./feed-directory.js URL in the built HTML. On GitHub Pages that resolves to /feed-directory/feed-directory.js, which 404s, so the client never ran and the instance catalog API was never requested.

Risk

  • Low — one-line script loading change; behavior unchanged once the bundle loads.
  • After deploy, confirm /feed-directory/ requests {instance}/api/v1/configs in the network panel.

Review map

Review map: whole PR is small — start at src/components/FeedDirectory.astro.

Validation

  • make build (exit 0)
  • Verified built dist/feed-directory/index.html references /_astro/FeedDirectory.astro_astro_type_script_index_0_lang.*.js, not ./feed-directory.js

The feed directory referenced ./feed-directory.js as a raw src URL, which
404'd in production and prevented GET /api/v1/configs from ever running.
Use an inline Astro script import so Vite emits a hashed /_astro/ bundle.
@gildesmarais
gildesmarais merged commit 0e48fa9 into main Aug 22, 2026
4 of 5 checks passed
@gildesmarais
gildesmarais deleted the fix/feed-directory-catalog-script branch August 22, 2026 11:07
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.

1 participant