I'd like to gauge interest / comments for an easier way to customize index.html output.
Use-case
We have some dynamic values that we want to interpolate into the index.html file at build time. For example, static classes on the <html> element and special meta attributes.
Ember already provides the content-for hook, but adding individual attributes to specific html elements is trickier.
Possible solution
- Exposing the internal
configReplacePatterns API, for example a addReplacePattern method or a key under config (environment.js), say additionalReplacePatterns: [ … ]
- Allowing custom 'slots' for use with
{{content-for 'my-slot'}}.
Reference code
https://github.com/ember-cli/ember-cli/blob/b24b73b388934796ca915ca665b48a27c857199b/lib/utilities/ember-app-utils.js#L169
I'd like to gauge interest / comments for an easier way to customize index.html output.
Use-case
We have some dynamic values that we want to interpolate into the index.html file at build time. For example, static classes on the
<html>element and special meta attributes.Ember already provides the
content-forhook, but adding individual attributes to specific html elements is trickier.Possible solution
configReplacePatternsAPI, for example aaddReplacePatternmethod or a key under config (environment.js), sayadditionalReplacePatterns: [ … ]{{content-for 'my-slot'}}.Reference code
https://github.com/ember-cli/ember-cli/blob/b24b73b388934796ca915ca665b48a27c857199b/lib/utilities/ember-app-utils.js#L169