Skip to content

ts eslint config issue #10640

Open
Open

Description

@chancancode

https://github.com/ember-cli/ember-cli/blob/master/blueprints/app/files/package.json#L31-L33

@babel/eslint-parser and @babel/plugin-proposal-decorators are not installed for TypeScript project.

In the old legacy config, TS projects always use the TS parser even for JS files:

https://github.com/ember-cli/ember-cli/blob/v6.0.0/blueprints/app/files/.eslintrc.js#L5-L36

The new flat config for TS projects references the babel parsers when they aren't available:

https://github.com/ember-cli/ember-cli/blob/master/blueprints/app/files/_ts_eslint.config.mjs#L26-L42

@NullVoxPopuli any reason you didn't want to just unconditionally use the TS parser like the old config did?

Activity

  1. NullVoxPopuli commented on Feb 15, 2025

    @NullVoxPopuli
    Contributor

    any reason you didn't want to just unconditionally use the TS parser like the old config did?

    the ts lints usually have a different cost in performance, so I didn't want to force them on js folks out of the box.

    The whole matrix of what to support is way easier to handle when you can just declare everything as a dependencies entry, and conditionally build your config, as done here:

    https://github.com/NullVoxPopuli/ember-eslint/blob/main/src/official.js#L18

  2. chancancode commented on Feb 15, 2025

    @chancancode
    ContributorAuthor

    the ts lints usually have a different cost in performance, so I didn't want to force them on js folks out of the box.

    does that happen just by using it as the parser?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions