Skip to content

Proposal: warn on /index imports #985

@mike1808

Description

@mike1808

My IDE likes to add /index to the import path when I specify some folder path with index.js file in it. For example:

- module
    - index.js

- file.js
// file.js
import module from './module'

and it becomes

// file.js
import module from './module/index'

Can we have a rule which disallows explicit specification of the index file?

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