This package has been deprecated

Author message:

Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

eslint-plugin-absolute-import

1.4.4 • Public • Published

eslint-plugin-absolute-import

build status Coverage Status win32 build status npm npm downloads

This plugin intends to support linting of ES2015+ (ES6+) import/export syntax, and prevent issues with misspelling of file paths and import names. All the goodness that the ES2015+ static module syntax intends to provide, marked up in your editor.

Rules

Static analysis

  • Forbid import of modules using relative paths ([no-relative-path])
  • Forbid unresolved imports ([no-unresolved])

Installation

npm install eslint-plugin-absolute-import -g

or if you manage ESLint as a dev dependency:

# inside your project's working tree 
npm install eslint-plugin-absolute-import --save-dev

All rules are off by default.

Currently [Node] and [webpack] resolution have been implemented, but the resolvers are just npm packages, so third party packages are supported (and encouraged!).

Settings

You may set the following settings in your .eslintrc:

import/extensions

A list of file extensions that will be parsed as modules and inspected for exports.

This defaults to ['.js'], unless you are using the react shared config, in which case it is specified as ['.js', '.jsx'].

"settings": {
  "import/resolver": {
    "node": {
      "extensions": [
        ".js",
        ".jsx"
      ]
    }
  }
}

Package Sidebar

Install

npm i eslint-plugin-absolute-import

Weekly Downloads

1,714

Version

1.4.4

License

MIT

Unpacked Size

112 kB

Total Files

23

Last publish

Collaborators

  • mcclowes