Skip to content

create-react-app enforces @typescript-eslint/no-namespace, a style rule #7651

Closed
@szhu

Description

@szhu

Describe the bug

  1. create-react-app --typescript
  2. Add a namespace in a file
  3. I get the error: ES2015 module syntax is preferred over custom TypeScript modules and namespaces.eslint(@typescript-eslint/no-namespace). There seems to be no way to turn off this rule, according to Support ESLint configure or disabling ESLint (discussion) #3886.

Why this is a bug:

From #2157 (comment):

Our rules are specifically picked to not enforce style, and to only find logical mistakes.

Whether or not a namespace is used is most definitely not a choice of style and not a logical mistake. Please remove this rule or give me an option to remove this rule.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions