[PR #3993] [MERGED] 🔧 Migrate to ESLint v9 #31068

Closed
opened 2026-04-18 07:20:52 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/actualbudget/actual/pull/3993
Author: @matt-fidd
Created: 12/16/2024
Status: Merged
Merged: 1/7/2025
Merged by: @matt-fidd

Base: masterHead: eslint-v9


📝 Commits (9)

📊 Changes

31 files changed (+1881 additions, -1239 deletions)

View changed files

.eslintignore (+0 -30)
.eslintrc.js (+0 -608)
eslint.config.mjs (+789 -0)
📝 package.json (+11 -11)
📝 packages/api/index.ts (+1 -1)
📝 packages/desktop-client/globals.d.ts (+1 -0)
📝 packages/desktop-client/playwright.config.js (+1 -1)
📝 packages/desktop-client/src/browser-preload.browser.js (+1 -0)
📝 packages/desktop-client/src/build-shims.js (+1 -2)
📝 packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.tsx (+0 -1)
📝 packages/desktop-client/vite.config.mts (+1 -1)
📝 packages/desktop-electron/beforePackHook.ts (+1 -1)
packages/eslint-plugin-actual/.eslintrc.js (+0 -26)
packages/eslint-plugin-actual/lib/rules/__tests__/prefer-if-statement.js (+0 -139)
packages/eslint-plugin-actual/lib/rules/__tests__/prefer-if-statement.test.js (+140 -0)
packages/eslint-plugin-actual/lib/rules/__tests__/typography.js (+0 -70)
packages/eslint-plugin-actual/lib/rules/__tests__/typography.test.js (+71 -0)
📝 packages/eslint-plugin-actual/lib/rules/prefer-if-statement.js (+0 -2)
📝 packages/eslint-plugin-actual/lib/rules/typography.js (+0 -2)
📝 packages/eslint-plugin-actual/package.json (+3 -3)

...and 11 more files

📄 Description

This is quite a big change diff wise, it took /far/ too long to get the new flat config format to work.

Unfortunately, I can not get the below rule to work. When enabled, ESLint crashes completely, with very little in the way of useful logging.

'import/no-unused-modules': ['warn', { unusedExports: true }]

I also fixed some strict usage that it was complaining about in the custom rule package.

These errors are new in this new config. I've ignored them, but if you can see better fixes please shout.

actual/packages/desktop-client/globals.d.ts
  1:32  error  Unable to resolve path to module '@emotion/css/dist/declarations/src/create-instance'  import/no-unresolved

actual/packages/desktop-client/src/browser-preload.browser.js
  2:28  error  Unable to resolve path to module 'virtual:pwa-register'  import/no-unresolved

actual/packages/loot-core/src/platform/client/undo/index.d.ts
  1:32  error  Unable to resolve path to module '../../client/state-types/modals'  import/no-unresolved

actual/packages/loot-core/src/types/server-handlers.d.ts
  21:23  error  Unable to resolve path to module './query'  import/no-unresolved

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/actualbudget/actual/pull/3993 **Author:** [@matt-fidd](https://github.com/matt-fidd) **Created:** 12/16/2024 **Status:** ✅ Merged **Merged:** 1/7/2025 **Merged by:** [@matt-fidd](https://github.com/matt-fidd) **Base:** `master` ← **Head:** `eslint-v9` --- ### 📝 Commits (9) - [`8ab1801`](https://github.com/actualbudget/actual/commit/8ab18012292f69388c4ba080469850ace295f4e8) note - [`18b1c90`](https://github.com/actualbudget/actual/commit/18b1c90d4cfefaa13ea0fcf863bf7004b4d3d7b8) bump eslint - [`53042ea`](https://github.com/actualbudget/actual/commit/53042ea458154eb5aecd7e88315ccc99261af456) convert to eslint v9 flat config format - [`860d444`](https://github.com/actualbudget/actual/commit/860d444b50d1020d34ebc2de7d017162f1a589e1) fix strict errors - [`35a983e`](https://github.com/actualbudget/actual/commit/35a983e9deae7ca0da07bdd0186a2b3141e43e5e) remove no-unused-modules - [`572f6d0`](https://github.com/actualbudget/actual/commit/572f6d0e42175388d250676f36e075df4471a26f) ignore residual errors - [`86ab57b`](https://github.com/actualbudget/actual/commit/86ab57b6d1dc29c0a47f483ffc647bebec83cdcc) Patch tests - [`f4a799c`](https://github.com/actualbudget/actual/commit/f4a799ca6f23885833cf1e5d3f56f0de57016a3f) Patch lint - [`29ee121`](https://github.com/actualbudget/actual/commit/29ee1219a526c58083878e36208da536f562dbe9) More linter patches ### 📊 Changes **31 files changed** (+1881 additions, -1239 deletions) <details> <summary>View changed files</summary> ➖ `.eslintignore` (+0 -30) ➖ `.eslintrc.js` (+0 -608) ➕ `eslint.config.mjs` (+789 -0) 📝 `package.json` (+11 -11) 📝 `packages/api/index.ts` (+1 -1) 📝 `packages/desktop-client/globals.d.ts` (+1 -0) 📝 `packages/desktop-client/playwright.config.js` (+1 -1) 📝 `packages/desktop-client/src/browser-preload.browser.js` (+1 -0) 📝 `packages/desktop-client/src/build-shims.js` (+1 -2) 📝 `packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.tsx` (+0 -1) 📝 `packages/desktop-client/vite.config.mts` (+1 -1) 📝 `packages/desktop-electron/beforePackHook.ts` (+1 -1) ➖ `packages/eslint-plugin-actual/.eslintrc.js` (+0 -26) ➖ `packages/eslint-plugin-actual/lib/rules/__tests__/prefer-if-statement.js` (+0 -139) ➕ `packages/eslint-plugin-actual/lib/rules/__tests__/prefer-if-statement.test.js` (+140 -0) ➖ `packages/eslint-plugin-actual/lib/rules/__tests__/typography.js` (+0 -70) ➕ `packages/eslint-plugin-actual/lib/rules/__tests__/typography.test.js` (+71 -0) 📝 `packages/eslint-plugin-actual/lib/rules/prefer-if-statement.js` (+0 -2) 📝 `packages/eslint-plugin-actual/lib/rules/typography.js` (+0 -2) 📝 `packages/eslint-plugin-actual/package.json` (+3 -3) _...and 11 more files_ </details> ### 📄 Description This is quite a big change diff wise, it took /far/ too long to get the new flat config format to work. Unfortunately, I can not get the below rule to work. When enabled, ESLint crashes completely, with very little in the way of useful logging. ```js 'import/no-unused-modules': ['warn', { unusedExports: true }] ``` I also fixed some strict usage that it was complaining about in the custom rule package. These errors are new in this new config. I've ignored them, but if you can see better fixes please shout. ``` actual/packages/desktop-client/globals.d.ts 1:32 error Unable to resolve path to module '@emotion/css/dist/declarations/src/create-instance' import/no-unresolved actual/packages/desktop-client/src/browser-preload.browser.js 2:28 error Unable to resolve path to module 'virtual:pwa-register' import/no-unresolved actual/packages/loot-core/src/platform/client/undo/index.d.ts 1:32 error Unable to resolve path to module '../../client/state-types/modals' import/no-unresolved actual/packages/loot-core/src/types/server-handlers.d.ts 21:23 error Unable to resolve path to module './query' import/no-unresolved ``` --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-18 07:20:52 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/actual#31068