This package provides HMLBars/Glimmer syntax highlighting for template (.hbs
)
files as well as inline template declaration in JS files.
To activate syntax highlighting in template files select Ember Glimmer
as the
language. Glimmer highlighting is automatically applied to any inline template
declaration in JS files.
Ember component test files are automatically generated with inline template string syntax, eg:
this.render(hbs`{{#some-component}}Syntax highlighting is the best.{{/some-component}}`);
But you can also declare templates for components using a tagged template string and the layout
property!
import Ember from 'ember';import hbs from 'htmlbars-inline-precompile';export default Ember.component.extend({// Component layout using tagged template string:layout: hbs`<span>Hello there, {{name}}</span>`});
This package will match the hbs` `
declaration and apply syntax highlighting
to template string contents.
Cmd + /
.unescaped.block.htmlbars
string.of.property.function.component.name.htmlbars
support.function.builtin.inline.htmlbars
See CONTRIBUTING.md
for technical details.
language-ember-htmlbars for ideas on regex patterns.
Good catch. Let us know what about this package looks wrong to you, and we'll investigate right away.