1.0.5 • Published 4 years ago

eslint-config-nahid v1.0.5

Weekly downloads
7
License
MIT
Repository
github
Last release
4 years ago

eslint-config-nahid

My sharable and pluggable ESLint + Prettier configuration.

Contents

Features

Requirements

Installation

  1. If your project doesn't have a package.json file already, create one using the npm init command.
  2. Run the command: npx install-peerdeps --dev eslint-config-nahid
  3. Create a file named .eslintrc and insert the following there:
{
	"extends": [ "nahid" ]
}

This object can also be added in your package.json file instead under the eslintConfig property.

Learn more about using shareable ESLint config here.

Usage

  1. You can try running the following command eslint . to run ESLint. Look at ESLint's command-line interface guide here.
  2. I prefer adding two scripts to the package.json file:
"scripts": {
	"lint-js": "eslint \"**/*.js\"",
	"lint-js:fix": "eslint \"**/*.js\" --fix",
}

That way, I can run npm run lint-js and npm run lint-js:fix to lint and lint/fix all the JS files in the codebase.

The documentation for ESLint as a whole can be found here.