Skip to content

Conversation

lumirlumir
Copy link
Member

@lumirlumir lumirlumir commented Sep 17, 2025

Prerequisites checklist

What is the purpose of this pull request?

In this PR, I've migrated to ESLint v9.

It seems that it's been a while since the ESLint configuration was last updated.

I've referenced the CommonJS setup in the following link:

https://github.com/eslint/eslint-github-bot/blob/main/eslint.config.js

I've only updated the JavaScript code that was reported by the new rules.

What changes did you make? (Give an overview)

In this PR, I've migrated to ESLint v9.

Related Issues

Ref: #75, #72

Is there anything you'd like reviewers to focus on?

N/A

@eslintbot eslintbot added this to Triage Sep 17, 2025
@github-project-automation github-project-automation bot moved this to Needs Triage in Triage Sep 17, 2025
@lumirlumir lumirlumir force-pushed the refactor-migrate-to-eslint-v9 branch from b24b643 to dd66af8 Compare September 17, 2025 14:47
"require-unicode-regexp": "off",
"regexp/optimal-quantifier-concatenation": "off",
"n/no-process-exit": "off",
"n/no-unsupported-features/es-syntax": "off",
Copy link
Member Author

@lumirlumir lumirlumir Sep 18, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

It appears that hashbang is not supported in Node.js v10.

I'm not sure what the best approach would be here, so I've disabled it for now.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I prepared a PR to drop node.js <18: #77

Comment on lines +13 to +14
"require-unicode-regexp": "off",
"regexp/optimal-quantifier-concatenation": "off",
Copy link
Member Author

@lumirlumir lumirlumir Sep 18, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems that updating the regex may not be appropriate here given the formal .eslintrc.yml setup, so I’ve turned it off.

require-unicode-regexp: 0

uses: actions/setup-node@v5
with:
node-version: '12.x'
node-version: '22.x'
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The CI only runs the lint script, and ESLint v9 requires Node.js 18 or newer, so I've set it to Node.js 22.

@lumirlumir lumirlumir marked this pull request as ready for review September 18, 2025 14:42
@aladdin-add aladdin-add moved this from Needs Triage to Implementing in Triage Sep 18, 2025
@lumirlumir lumirlumir marked this pull request as draft September 20, 2025 12:50
@lumirlumir
Copy link
Member Author

I'm marking this as a draft until #77 is resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Implementing
Development

Successfully merging this pull request may close these issues.

2 participants