Détail du package

eslint-config-phun-ky

phun-ky662MIT1.0.8

An opinionated eslint-config that someone else could also use, with more than 450 helpful ESLint rules

eslint, eslint-config

readme

eslint-config-phun-ky

An opinionated eslint-config that someone else could also use, with more than 450 helpful ESLint rules :)

Commitizen friendly PRs Welcome SemVer 2.0 npm version issues license size npm GitHub Repo stars

Table of Contents

Install

npm i -D eslint eslint-config-phun-ky

Requires ESLint >=9.20.0 and flat config.

Usage

// eslint.config.js
import { defineConfig } from 'eslint/config';
import customConfig from 'eslint-config-phun-ky';

export default defineConfig([
  {
    files: ['**/*.js'],
    extends: [customConfig],

    // anything from here will override customConfig
    rules: {
      '@stylistic/no-extra-semi': '0'
    }
  }
]);

Files

By default, the config covers these files:

['**/*.{js,mjs,cjs,ts,tsx,md}']

Rules

The custom rules extends/overrides these configs and plugins:

{
  …,
  {
    ...markdown.configs.recommended,
    eslint.configs.recommended,
    importPlugin.flatConfigs.recommended,
    importPlugin.flatConfigs.typescript,
    compat.configs['flat/recommended'],
    ...tsConfigs.recommended,
    eslintPluginPrettierRecommended,
  },
  plugins: {
    '@stylistic': stylistic
  },
  …
}

Extended

🔧 Automatically fixable with --fix CLI option.

Rule Description 🔧
import/no-named-as-default Disallows named imports that may conflict with default exports.
import/no-unused-modules Reports modules without any exports or imports used elsewhere.
import/order Enforces a consistent order for import statements. 🔧
no-alert Disallows alert, confirm, and prompt.
no-console Disallows use of console.
no-undef Disallows the use of undeclared variables unless mentioned in /*global */ comments.
no-unreachable Disallows unreachable code after return, throw, continue, and break.
prefer-const Suggests using const declaration for variables that are never reassigned. 🔧
one-var Enforces variables to be declared either together or separately in functions. 🔧
@stylistic/array-bracket-newline Enforces line breaks inside brackets. 🔧
@stylistic/max-len Enforces a maximum line length.
@stylistic/quotes Enforces the consistent use of quotes. 🔧
@stylistic/padded-blocks Enforces or disallows padding within blocks. 🔧
@stylistic/comma-dangle Requires or disallows trailing commas. 🔧
@stylistic/padding-line-between-statements Requires or disallows blank lines between statements. 🔧
@stylistic/indent Enforces consistent indentation. 🔧
@stylistic/object-curly-spacing Enforces consistent spacing inside braces. 🔧
@stylistic/no-extra-semi Disallows unnecessary semicolons. 🔧
@stylistic/no-trailing-spaces Disallows trailing whitespace at the end of lines. 🔧
@stylistic/semi Enforces or disallows semicolons. 🔧
no-irregular-whitespace Disallows irregular whitespace. 🔧

Contributing

Want to contribute? Please read the CONTRIBUTING.md and CODE_OF_CONDUCT.md

License

This project is licensed under the MIT License - see the LICENSE file for details.

Changelog

See the CHANGELOG.md for details on the latest updates.

Sponsor me

I'm an Open Source evangelist, creating stuff that does not exist yet to help get rid of secondary activities and to enhance systems already in place, be it documentation or web sites.

The sponsorship is an unique opportunity to alleviate more hours for me to maintain my projects, create new ones and contribute to the large community we're all part of :)

Support me on GitHub Sponsors.

p.s. Ukraine is still under brutal Russian invasion. A lot of Ukrainian people are hurt, without shelter and need help. You can help in various ways, for instance, directly helping refugees, spreading awareness, putting pressure on your local government or companies. You can also support Ukraine by donating e.g. to Red Cross, Ukraine humanitarian organisation or donate Ambulances for Ukraine.

changelog

Changelog

1.0.7 (2025-06-23)

Tasks

  • 🤖 bump @stylistic/eslint-plugin in the major-updates group (e524c9e)

1.0.6 (2025-06-16)

Tasks

  • 🤖 bump the minor-and-patch group with 2 updates (665d0cd)

1.0.5 (2025-06-09)

Tasks

  • 🤖 bump the minor-and-patch group with 4 updates (fe30964)

1.0.4 (2025-06-02)

Tasks

  • 🤖 bump the minor-and-patch group with 5 updates (b0bdfa8)

1.0.3 (2025-05-26)

Tasks

  • 🤖 bump the minor-and-patch group with 3 updates (ba744c9)

1.0.2 (2025-05-20)

Tasks

  • 🤖 bump the minor-and-patch group with 3 updates (dae8283)

1.0.1 (2025-05-12)

Tasks

  • 🤖 Add custom labels for PR size addon (431e86e)
  • 🤖 bump the minor-and-patch group with 2 updates (96cb13a)

1.0.0 (2025-05-06)

⚠ BREAKING CHANGES

  • 🧨 To follow the "standard" with ESLint config naming, I've renamed the package to eslint-config-phun-ky. The previous package is to be deprecated

Tasks

  • 🤖 Reinstall (b12fd31)
  • 🤖 Rename package to eslint-config-phun-ky (8822fc6)

Documentation

  • ✏️ Add more documentation about the rules and files (c8653c1)

Feature

  • 🎸 Add tsx into files array (9cea048)

Bug

  • 🐛 Remove deprecated rule, turn on no-alert (644ef78)

0.1.12 (2025-05-06)

Tasks

  • 🤖 Move eslint related stuff from dev dep to dep (a4e1931)
  • 🤖 Sort package.json (3349c0c)

0.1.11 (2025-05-05)

Tasks

  • 🤖 bump the minor-and-patch group with 4 updates (6d036e5)

0.1.10 (2025-05-04)

Bug

  • 🐛 Turn off some rules for markdown linting that is broken (d168096)

0.1.9 (2025-05-02)

Tasks

  • 🤖 Add more files to trigger check (916bfe2)

0.1.8 (2025-05-02)

0.1.7 (2025-05-02)

0.1.6 (2025-04-29)

Tasks

  • 🤖 bump the minor-and-patch group with 2 updates (527792c)

0.1.5 (2025-04-22)

Tasks

  • 🤖 bump release-it in the major-updates group (0b22ed5)

0.1.4 (2025-04-21)

Tasks

  • 🤖 bump the minor-and-patch group with 5 updates (eed6a2c)

0.1.3 (2025-04-15)

Tasks

  • 🤖 bump the minor-and-patch group with 2 updates (95248f2)

0.1.2 (2025-04-08)

Tasks

  • 🤖 bump eslint-import-resolver-typescript (403565a)

0.1.1 (2025-04-04)

Tasks

  • 🤖 bump prettier from 3.5.1 to 3.5.3 in the minor-and-patch group (5957a33)

0.1.0 (2025-04-04)

Tasks

  • 🤖 bump eslint-import-resolver-typescript (fc969e3)

Documentation

  • ✏️ Remove old banner (2f52358)

Feature

  • 🎸 First version of my opinionated eslintconfig (0adea9e)

Bug

  • 🐛 Add missing dev deps (df8db08)
  • 🐛 Add missing script (7670fe0)
  • 🐛 Fix release it process (1bed20c)