Skip to content

Keep inline template scripts out of Bend bundles - #2323

Draft
oxura wants to merge 1 commit into
bendlang:mainfrom
oxura:fix/html-template-inline-20261124
Draft

oxura wants to merge 1 commit into
bendlang:mainfrom
oxura:fix/html-template-inline-20261124

Conversation

@oxura

@oxura oxura commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

Inline module scripts inside HTML templates are inert. Bend now leaves them in the page instead of adding them to the JS bundle.

Fixes #2322.

I bundled a page with nested templates between two active scripts. Both inert script bodies stayed byte-for-byte in the HTML, while both active scripts made it into the JS. The old bundler refused that page. The Linux repo gate passed 56/56; the site-backed ping gate wasn't run.

- Track HTML template nesting in both rewriter passes so inert scripts remain in the page and active siblings are bundled.

Fixes bendlang#2322
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.

Bend bundles inert inline scripts inside HTML templates

1 participant