Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update runtime details for #931 #981

Merged
merged 2 commits into from
Oct 27, 2023
Merged

Update runtime details for #931 #981

merged 2 commits into from
Oct 27, 2023

Conversation

chancancode
Copy link
Member

This brings back some details about runtime template compilation that got lost from #813

@chancancode chancancode requested a review from ef4 October 24, 2023 17:28
This brings back some details about runtime template compilation
that got lost from #813

The new `"@ember/template-compiler/runtime"` module is interned to serve as a replacement for this, which better aligns with the direction we are headed. For example, this module can be imported on only the routes that needs it, and in conjunction with route-based code splitting that would reduce the performance hit on the initial load.

Note that, even with the template compilation is available at runtime, the result of the compilations may be subtly different – applications may have custom glimmer/handlebars AST plugins in their build, and these plugins will not be available at runtime.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's probably not important to mention here, but for posterity, if someone wanted to add their template plugins they'd need to set up babel, similar to: https://github.com/NullVoxPopuli/limber/blob/main/packages/ember-repl/addon/src/browser/gjs.ts#L39

and pass their template plugins via: https://github.com/emberjs/babel-plugin-ember-template-compilation/ 's transforms

@ef4 ef4 merged commit 7b4e42b into master Oct 27, 2023
8 checks passed
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