feat: re-export hbs parser and document HBS flat-config setup#2715
Merged
NullVoxPopuli merged 2 commits intoApr 21, 2026
Conversation
Adds `hbsParser` as a named export alongside the existing `parser` (gjs/gts) in `eslint-plugin-ember/recommended`, so consumers don't need a direct `ember-eslint-parser` devDep to wire up `.hbs` linting. README migration section now shows the HBS block and warns about the rule-merging pitfall when a typescript-eslint shared config matches `.hbs` (e.g. `recommendedTypeChecked` without its own `files` glob).
The .mjs override meant to disable `import/no-unresolved` but silently never did because of the typo. Surfaced when the new subpath import of `ember-eslint-parser/hbs` tripped the rule; the existing main-entry import resolved fine so the typo went unnoticed.
NullVoxPopuli
approved these changes
Apr 21, 2026
This was referenced Apr 21, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
hbsParseras a named export fromeslint-plugin-ember/recommended(alongside the existingparserfor gjs/gts). Lets consumers set up.hbslinting without addingember-eslint-parseras a direct devDep..hbsfiles" subsection under "Migrating from ember-template-lint" with a ready-to-paste flat-config block and a warning about the rule-merging pitfall when a typescript-eslint shared config's blocks (e.g.recommendedTypeChecked) don't set their ownfilesand therefore match.hbsalongside everything else.Motivation
A user migrating from
ember-template-linthit:and later:
Both errors come from
@typescript-eslint/parser's project service being applied to.hbsfiles via a broad shared-config block. The README didn't document the HBS flat-config wiring, so this was left for each consumer to figure out. This PR closes that gap.Test plan
npx vitest run tests/recommended.js tests/plugin-exports.js tests/config-setup.js— all passimport { hbsParser } from 'eslint-plugin-ember/recommended'resolves and exposesparseForESLintnpx markdownlint README.mdclean