From da3951773c1147020ea30ea5b8b38844272ccd71 Mon Sep 17 00:00:00 2001 From: Tony Ganchev Date: Sun, 15 Mar 2026 19:56:18 +0200 Subject: [PATCH] chore: switch to @tony.ganchev/eslint-plugin-header Hi, team, I noticed you are using _eslint-plugin-header_ with the schema-turn-off workaround to support ESLint 9. I forked _@tony.ganchev/eslint-plugin-header_ mid-2024 to address this issue and hoped it would be a temporary measure but since the original has not been updated for five years I decided to continue improving the new plugin and have been doing so for the last two years. Specific improvements include: - full JSON schema for validating the configuration. - fixed multiple bugs with the behavior of the plugin on Windows. - many other bug-fixes. - improved autofixing and error-reporting behavior. - added support for leading pragma comments before the header such as @jest-environment. I've sent PR proposals to other projects in the cloudscape-design space: - https://github.com/cloudscape-design/collection-hooks/pull/136 - https://github.com/cloudscape-design/components/pull/4308 - https://github.com/cloudscape-design/demos/pull/243 Looking forward to your feedback. --- eslint.config.js | 2 +- package-lock.json | 22 +++++++++++----------- package.json | 2 +- 3 files changed, 13 insertions(+), 13 deletions(-) diff --git a/eslint.config.js b/eslint.config.js index 9f98005..523fffc 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -3,7 +3,7 @@ const eslint = require('@eslint/js'); const tsEslint = require('typescript-eslint'); const unicornPlugin = require('eslint-plugin-unicorn'); -const headerPlugin = require('eslint-plugin-header'); +const headerPlugin = require('@tony.ganchev/eslint-plugin-header'); const prettierPlugin = require('eslint-plugin-prettier'); const prettierConfig = require('eslint-config-prettier'); diff --git a/package-lock.json b/package-lock.json index fb07594..3c561d5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -24,6 +24,7 @@ }, "devDependencies": { "@testing-library/react": "^16.2.0", + "@tony.ganchev/eslint-plugin-header": "^3.3.1", "@tsconfig/node18": "^18.2.2", "@types/babel__core": "^7.1.16", "@types/glob": "^9.0.0", @@ -34,7 +35,6 @@ "@vitest/coverage-istanbul": "^3.0.7", "eslint": "^9.39.1", "eslint-config-prettier": "^10.1.8", - "eslint-plugin-header": "^3.1.1", "eslint-plugin-prettier": "^5.5.4", "eslint-plugin-unicorn": "^62.0.0", "husky": "^9.1.7", @@ -1765,6 +1765,16 @@ } } }, + "node_modules/@tony.ganchev/eslint-plugin-header": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/@tony.ganchev/eslint-plugin-header/-/eslint-plugin-header-3.3.1.tgz", + "integrity": "sha512-/Fj0+DaXbBfrlXmd3wBZkB8TIwGT3N++y/oTYxRABK/gzNxjgcBjt63xBpuHCYIXmH1EwuALd6XS1fzNG4S0zg==", + "dev": true, + "license": "MIT", + "peerDependencies": { + "eslint": ">=7.7.0" + } + }, "node_modules/@tsconfig/node18": { "version": "18.2.2", "resolved": "https://registry.npmjs.org/@tsconfig/node18/-/node18-18.2.2.tgz", @@ -3300,16 +3310,6 @@ "eslint": ">=7.0.0" } }, - "node_modules/eslint-plugin-header": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/eslint-plugin-header/-/eslint-plugin-header-3.1.1.tgz", - "integrity": "sha512-9vlKxuJ4qf793CmeeSrZUvVClw6amtpghq3CuWcB5cUNnWHQhgcqy5eF8oVKFk1G3Y/CbchGfEaw3wiIJaNmVg==", - "dev": true, - "license": "MIT", - "peerDependencies": { - "eslint": ">=7.7.0" - } - }, "node_modules/eslint-plugin-prettier": { "version": "5.5.4", "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-5.5.4.tgz", diff --git a/package.json b/package.json index 88e4d02..3d13d48 100644 --- a/package.json +++ b/package.json @@ -32,6 +32,7 @@ }, "devDependencies": { "@testing-library/react": "^16.2.0", + "@tony.ganchev/eslint-plugin-header": "^3.3.1", "@tsconfig/node18": "^18.2.2", "@types/babel__core": "^7.1.16", "@types/glob": "^9.0.0", @@ -42,7 +43,6 @@ "@vitest/coverage-istanbul": "^3.0.7", "eslint": "^9.39.1", "eslint-config-prettier": "^10.1.8", - "eslint-plugin-header": "^3.1.1", "eslint-plugin-prettier": "^5.5.4", "eslint-plugin-unicorn": "^62.0.0", "husky": "^9.1.7",