1.0.0 • Published 2 years ago

@sulcata/eslint-config v1.0.0

Weekly downloads
3
License
MIT
Repository
github
Last release
2 years ago

@sulcata/eslint-config

npm latest version npm weekly downloads GitHub GitHub Workflow Deployment Status GitHub Workflow Integration Status supported node versions

A shareable set of ESLint configurations for TypeScript, React, and more. Intended to be opinionated in practices, not style.

If you're looking for opinionated style, I highly recommend Prettier.

Install

npm install @sulcata/eslint-config

Sadly because of the way the configuration system currently works, you'll also need to install the following peer dependencies for now.

npm install eslint-plugin-jest eslint-plugin-jsx-a11y eslint-plugin-react eslint-plugin-react-hooks

Once ESLint starts rolling out the new configuration system, this package will be changed to bundle them transparently.

Usage

Writing your ESLint .eslintrc.js config file can be as simple as:

"use strict";

module.exports = {
  root: true,
  parserOptions: {
    tsconfigRootDir: __dirname,
    project: ["./tsconfig.json"],
  },
  extends: ["@sulcata/eslint-config"],
};

This package exports a number of shareable configs that can be imported into your configuration using the ESLint config "extends" key.

  • @sulcata/eslint-config The kitchen sink, most likely what you want for minimal configuration. Pre-configured using the overrides feature to match file extensions to the appropriate configs. Includes recommended, typescript, react, and jest. Requires tsconfigRootDir and project to be configured in parserOptions for type information.
  • @sulcata/eslint-config/recommended for general JavaScript linting.
  • @sulcata/eslint-config/typescript for TypeScript linting. Requires tsconfigRootDir and project to be configured in parserOptions for type information.
  • @sulcata/eslint-config/react for React apps.
  • @sulcata/eslint-config/jest for Jest test suites.

Issues

Raise an issue (or a PR) if you notice any styling related rules bubbling up.

GitHub Issues

License

MIT License

1.0.0

2 years ago

0.4.1

3 years ago

0.4.0

3 years ago

0.3.0

3 years ago

0.2.0

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago

0.0.1

3 years ago