Skip to content

Conversation

tylerbutler
Copy link
Member

@tylerbutler tylerbutler commented Oct 10, 2025

More context: #25628

Migrate to eslint-plugin-import-x as eslint-plugin-import is no longer maintained.
Updated all references in config files and dependencies.

Once this is released, integration into main will require renaming comments and overrides, but the changes will be mechanical.

This is technically a breaking change, so I bumped it to a major. Regardless, I want to integrate this change alone, so I want to release once this is merged. The only question is if this needs to be a major release. If so, that's fine, but several of the subsequent changes will also be "breaking" so we'll be releasing several majors in short succession. I think that's fine.

Blocking

@Copilot Copilot AI review requested due to automatic review settings October 10, 2025 00:18
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR migrates the eslint-config-fluid package from the unmaintained eslint-plugin-import to its actively maintained successor eslint-plugin-import-x. The migration involves updating the package dependency and systematically replacing all rule names and configuration references throughout the ESLint configuration files.

  • Updated package.json to replace eslint-plugin-import dependency with eslint-plugin-import-x
  • Migrated all ESLint rule names from import/* to import-x/* namespace
  • Updated plugin references, settings, and documentation URLs to use the new plugin

Reviewed Changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated no comments.

File Description
common/build/eslint-config-fluid/package.json Updates dependency from eslint-plugin-import to eslint-plugin-import-x
common/build/eslint-config-fluid/minimal-deprecated.js Migrates all import plugin references to import-x throughout the configuration
common/build/eslint-config-fluid/base.js Updates base configuration to use import-x plugin and rule names
Files not reviewed (1)
  • common/build/eslint-config-fluid/pnpm-lock.yaml: Language not supported

…nt-plugin-import-x

Migrate to eslint-plugin-import-x as eslint-plugin-import is no longer maintained.
Updated all references in config files and dependencies.
@tylerbutler tylerbutler force-pushed the 1-migrate-import-plugin branch from b168acc to 8afcc54 Compare October 10, 2025 00:25
@tylerbutler tylerbutler requested review from a team October 10, 2025 00:45
".cts",
".mts",
".tsx",
".d.ts",
Copy link
Contributor

Choose a reason for hiding this comment

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

The changes to node.extensions seem to match what the base.js file says they should be... but before they were something different. We should understand the implications here and decide if maybe the extensions for the node case (I also don't get why it's separate from the "typescript" case) need adjustments.

Copy link
Member Author

Choose a reason for hiding this comment

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

I'll look into this.

Copy link
Member Author

Choose a reason for hiding this comment

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

I think resolvers work differently in import-x, and I have updated the entries to omit node entirely. I'll see if that works.

".tsx",
".d.ts",
".tsx"
".mts"
Copy link
Contributor

Choose a reason for hiding this comment

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

Another one I'd like to understand. I get .tsx was duplicated so cleaning up seems fine, but what introduced .mts? And why just that and not cts too?

Comment on lines +2324 to +2326
".jsx",
".cjs",
".mjs"
Copy link
Contributor

Choose a reason for hiding this comment

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

Similar to the two above, but this one seems more straightforward.

Comment on lines +1226 to +1227
"sortTypesGroup": false,
"named": false,
Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Member Author

Choose a reason for hiding this comment

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

Agreed. Keeping this pr series focused on getting us current as a priority though. My hope is that once we are on eslint 9 it will be easier to use in-repo config inheritance to manage our shared config like we do for tscobfig and api extractor. That will make it easier to roll out changes to the config without this crazy release dance. 🤞🤞🤞

},
},
],
settings: {
Copy link
Member Author

Choose a reason for hiding this comment

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

Moved to base.js

Copy link
Contributor

🔗 Found some broken links! 💔

Run a link check locally to find them. See
https://github.com/microsoft/FluidFramework/wiki/Checking-for-broken-links-in-the-documentation for more information.

linkcheck output


> fluid-framework-docs-site@0.0.0 ci:check-links /home/runner/work/FluidFramework/FluidFramework/docs
> start-server-and-test "npm run serve -- --no-open" 3000 check-links

1: starting server using command "npm run serve -- --no-open"
and when url "[ 'http://127.0.0.1:3000' ]" is responding with HTTP status code 200
running tests using command "npm run check-links"


> fluid-framework-docs-site@0.0.0 serve
> docusaurus serve --no-open

[SUCCESS] Serving "build" directory at: http://localhost:3000/

> fluid-framework-docs-site@0.0.0 check-links
> linkcheck http://localhost:3000 --skip-file skipped-urls.txt

 ELIFECYCLE  Command failed with exit code 1.

Copy link
Contributor

@alexvy86 alexvy86 left a comment

Choose a reason for hiding this comment

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

I'll admit I don't really follow everything that's happening in the printed configs, particularly under import-x/resolver, but seems to be just how it works since we didn't do any of that by hand... I think moving forward with this is fine and if we're missing any issues introduced here, fix them as we find them.

@alexvy86
Copy link
Contributor

@microsoft-github-policy-service rerun

@tylerbutler tylerbutler merged commit 183018b into microsoft:main Oct 14, 2025
34 checks passed
@tylerbutler tylerbutler deleted the 1-migrate-import-plugin branch October 14, 2025 16:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: build Build related issues base: main PRs targeted against main branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants