eslint-config-lucid

0.3.1 • Public • Published

Eslint Config Lucid

A collection of eslint plugins with settings focused on reducing cognitive load and improving readability.


Disclaimer

Lucid only supports the new flat config that shipped with ESLint v8.21.0


Installation

First install peer dependencies:

npm i eslint 

Next, install eslint-config-lucid:

npm i eslint-config-lucid

Add Lucid to your eslint.config.js configuration file.


About

Lucid starts from the eslint recommended settings. These rules are modified to support the intent of Lucid (see below), and other plugins are added as listed in the Rules section below.

Intent

When it comes to formatting and syntax rules, reducing cognitive load is the primary intent of Lucid. Unlike so many code linters and formatters, I endeavor to base all my decisions on researched psychological principals. Some principles considered are:

  • Gestalt psychology

    • Many of the rule decisions regarding code formatting are grounded in Gestalt Psychology, particularly around the use of whitespace to group like things and separate unlike things.
  • Programming complexity

If you want to propose a change to a rule or suggest additional plugins, please include researched psychological principals in your issue or pull request.


Rules

babel : object

ESLint rules for eslint-plugin-babel. Each rule corresponds to a core eslint rule, and has the same options. These allow modern ES features without throwing false errors.

core : object

Core ESLint rules.

you-dont-need-lodash-underscore : object

ESLint rules for eslint-plugin-you-dont-need-lodash-underscore.

node : object

ESLint rules for eslint-plugin-n. Note that .js files are set up for es module syntax just like .cjs.

prefer-arrow-functions : object

ESLint rules for eslint-plugin-prefer-arrow-functions.

promise : object

ESLint rules for eslint-plugin-promise.

regexp : object

ESLint rules for eslint-plugin-regexp.

security : object

ESLint rules for eslint-plugin-security.

@stylistic/js : object

ESLint rules for @stylistic/eslint-plugin-js.

@stylistic/plus : object

ESLint rules for @stylistic/eslint-plugin-plus.

unicorn : object

ESLint rules for eslint-plugin-unicorn.

Readme

Keywords

Package Sidebar

Install

npm i eslint-config-lucid

Weekly Downloads

2

Version

0.3.1

License

MIT

Unpacked Size

253 kB

Total Files

58

Last publish

Collaborators

  • darrenpaulwright