This content originally appeared on DEV Community and was authored by Michal Bryxí
Well technically in any *.js/*.ts
file, but my just got stuck on “this has to be part of ember-template-lint config”, because I’ve seen a component that is basically just HTML.
So if anyone bumps into this, the answer is NOT to put the config in .template-lintrc.js
, but to eslint.config.mjs
(or equivalent), in following way:
// eslint.config.mjs
export default ts.config(
{
files: ['**/*.{ts,gts}'],
languageOptions: {
parser: ember.parser,
parserOptions: parserOptions.esm.ts,
},
extends: [...ts.configs.recommendedTypeChecked, ember.configs.gts],
rules: {
'ember/no-empty-glimmer-component-classes': 'off',
},
},
);
This content originally appeared on DEV Community and was authored by Michal Bryxí