Skip to content

Support Vite builds in include_ember_script_tags - #33

Merged
tricknotes merged 1 commit into
mainfrom
claude/vite-ember-app-helper-m84n1u
Aug 22, 2026
Merged

Support Vite builds in include_ember_script_tags#33
tricknotes merged 1 commit into
mainfrom
claude/vite-ember-app-helper-m84n1u

Conversation

@tricknotes

Copy link
Copy Markdown
Owner

ember-cli >= 6.8 builds apps with Vite, where the assets required for startup (config meta tag, stylesheets, module preloads, and ES module scripts) are declared in dist/index.html instead of the classic vendor/app script pair.

Detect a Vite build from the module script in dist/index.html and inject the startup tags extracted from it, remapping root-absolute paths onto the mount point given by prepend. Classic builds keep the existing asset lookup behavior.

See also:

Comment thread app/helpers/ember_cli_rails_assets_helper.rb
Comment thread app/helpers/ember_cli_rails_assets_helper.rb
Comment thread app/helpers/ember_cli_rails_assets_helper.rb
Comment thread app/helpers/ember_cli_rails_assets_helper.rb
Comment thread app/helpers/ember_cli_rails_assets_helper.rb
Comment thread app/helpers/ember_cli_rails_assets_helper.rb
Comment thread app/helpers/ember_cli_rails_assets_helper.rb
Comment thread app/helpers/ember_cli_rails_assets_helper.rb
Comment thread app/helpers/ember_cli_rails_assets_helper.rb
Comment thread lib/ember_cli/assets/paths.rb
@tricknotes
tricknotes force-pushed the claude/vite-ember-app-helper-m84n1u branch from 3ba0dc4 to 5831c6d Compare August 22, 2026 03:35
ember-cli >= 6.8 builds apps with Vite, where the assets required for
startup (config meta tag, stylesheets, module preloads, and ES module
scripts) are declared in dist/index.html instead of the classic
vendor/app script pair.

Detect a Vite build from the module script in dist/index.html and
inject the startup tags extracted from it, remapping root-absolute
paths onto the mount point given by `prepend`. Classic builds keep
the existing asset lookup behavior.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@tricknotes
tricknotes force-pushed the claude/vite-ember-app-helper-m84n1u branch from 5831c6d to d7d3dbd Compare August 22, 2026 06:36
@tricknotes
tricknotes merged commit a0eb6ad into main Aug 22, 2026
8 of 9 checks passed
@tricknotes
tricknotes deleted the claude/vite-ember-app-helper-m84n1u branch August 22, 2026 14:14
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.

3 participants