eslint-plugin-prefer-named-export

1.0.7 • Public • Published

eslint-plugin-prefer-named-export

Installation

Use npm or a compatibility tool to install.

$ npm install --save-dev eslint eslint-plugin-prefer-named-export

Requirements

  • Node.js v8.10.0 or newer versions.
  • ESLint v5.16.0 or newer versions.

Usage

Write your config file such as .eslintrc.yml.

plugins:
  - prefer-named-export
rules:
  prefer-named-export/example-rule: error

See also Configuring ESLint.

Configs

  • prefer-named-export/recommended ... enables the recommended rules.

Rules

Possible Errors

Rule ID Description
prefer-named-export/prefer-named-export This rule enforces the use of named exports instead of default exports. It checks for export statements that use the export default syntax with an identifier as the default export, and suggests exporting the variable directly with a named export instead. ⭐️✒️

Semantic Versioning Policy

This plugin follows Semantic Versioning and ESLint's Semantic Versioning Policy.

Changelog

Contributing

Welcome your contribution!

See also ESLint Contribution Guide.

Development Tools

  • npm test runs tests.
  • npm run update updates the package version. And it updates src/configs/recommended.ts, lib/index.ts, and README.md's rule table. See also npm version CLI command.
  • npm run add-rule <RULE_ID> creates three files to add a new rule.

Package Sidebar

Install

npm i eslint-plugin-prefer-named-export

Weekly Downloads

1

Version

1.0.7

License

MIT

Unpacked Size

9.19 kB

Total Files

6

Last publish

Collaborators

  • richardaum