build(eslint-config-fluid): consolidate custom rules into config package - #27943
Conversation
Move the custom Fluid ESLint rules and their tests into eslint-config-fluid, then remove the standalone plugin package and release metadata. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: dd9688d7-f485-461a-9a13-1c3ef9f2322a
|
Hi! Thank you for opening this PR. Want me to review it? Based on the diff (6832 lines, 64 files), I've queued these reviewers:
How this works
|
There was a problem hiding this comment.
Pull request overview
This PR consolidates the custom Fluid ESLint rules into @fluidframework/eslint-config-fluid, removing the separate @fluid-internal/eslint-plugin-fluid package and its release pipeline while preserving the existing @fluid-internal/fluid/* rule namespace for consumers.
Changes:
- Removes the
@fluid-internal/eslint-plugin-fluidpackage, build pipeline, and related repo metadata references. - Adds the custom rules (and supporting utilities) directly under
common/build/eslint-config-fluid/rules/with afluidPlugin.cjsregistration shim. - Expands ESLint 8/9 test coverage in
eslint-config-fluidwith rule fixtures and mocha tests.
Reviewed changes
Copilot reviewed 28 out of 64 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| tools/pipelines/build-eslint-plugin-fluid.yml | Removes the ADO pipeline for the deleted eslint plugin package. |
| PACKAGES.md | Removes the plugin package from the documented package list. |
| layerInfo.json | Removes the plugin from layer/package metadata. |
| fluidBuild.config.cjs | Removes plugin package path and related config references. |
| common/build/eslint-plugin-fluid/README.md | Deletes removed plugin package documentation. |
| common/build/eslint-plugin-fluid/prettier.config.cjs | Deletes removed plugin package prettier config. |
| common/build/eslint-plugin-fluid/pnpm-workspace.yaml | Deletes removed plugin package workspace workaround file. |
| common/build/eslint-plugin-fluid/package.json | Deletes removed plugin package manifest. |
| common/build/eslint-plugin-fluid/mocha-multi-reporter-config.json | Deletes removed plugin package mocha reporter config. |
| common/build/eslint-plugin-fluid/LICENSE | Deletes removed plugin package license file. |
| common/build/eslint-plugin-fluid/index.js | Deletes removed plugin package entrypoint. |
| common/build/eslint-plugin-fluid/DEV.md | Deletes removed plugin package dev/publishing guide. |
| common/build/eslint-plugin-fluid/CHANGELOG.md | Deletes removed plugin package changelog. |
| common/build/eslint-plugin-fluid/.npmignore | Deletes removed plugin package npm ignore file. |
| common/build/eslint-plugin-fluid/.mocharc.json | Deletes removed plugin package mocha config. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/tsconfig.json | Adds TS config for compiling rule test fixtures. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-unchecked-record-access/undefinableIndexedRecord.ts | Adds fixture coverage for no-unchecked-record-access “ok” cases. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-unchecked-record-access/staticTypes.ts | Adds fixture coverage for static-type cases. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-unchecked-record-access/nullableIndexedRecord.ts | Adds fixture coverage for nullable index signature cases. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-unchecked-record-access/nestedIndexSignatures.ts | Adds fixture coverage for nested index signature cases. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-unchecked-record-access/indexedRecordOfStrings.ts | Adds fixture coverage for index signature access patterns. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-unchecked-record-access/generics.ts | Adds fixture coverage for generic record access patterns. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-unchecked-record-access/fileWithOnlyArrayAccess.ts | Adds fixture to ensure array-like access isn’t flagged. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-restricted-tags-imports/mockModule.ts | Adds fixture module with tagged exports for import restriction tests. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-restricted-tags-imports/fileWithImports.ts | Adds fixture that imports restricted-tag symbols. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-restricted-tags-imports/fileWithExceptionImports.ts | Adds fixture for exception import scenarios. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-restricted-tags-imports/exceptionFile.ts | Adds fixture defining exception-tagged exports. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-member-release-tags/mockType.ts | Adds fixtures for member release-tag rule (type). |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-member-release-tags/mockInterface.ts | Adds fixtures for member release-tag rule (interfaces). |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-member-release-tags/mockFunction.ts | Adds fixture to ensure standalone functions aren’t flagged. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-member-release-tags/mockClassExpression.ts | Adds fixtures for member release-tag rule (class expressions). |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-member-release-tags/mockClassDeclaration.ts | Adds fixtures for member release-tag rule (class declarations). |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-member-release-tags/mockAbstractClass.ts | Adds fixtures for member release-tag rule (abstract classes). |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-markdown-links-in-jsdoc/test.ts | Adds fixtures for markdown-link rule. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-hyphen-after-jsdoc-tag/test.ts | Adds fixtures for hyphen-after-tag rule. |
| common/build/eslint-config-fluid/src/test/rules/test-cases/no-file-path-links-in-jsdoc/test.ts | Adds fixtures for file-path-link rule. |
| common/build/eslint-config-fluid/src/test/rules/no-unchecked-record-access.test.js | Adds mocha tests for no-unchecked-record-access. |
| common/build/eslint-config-fluid/src/test/rules/no-restricted-tags-imports.test.js | Adds mocha tests for no-restricted-tags-imports. |
| common/build/eslint-config-fluid/src/test/rules/no-member-release-tags.test.js | Adds mocha tests for no-member-release-tags. |
| common/build/eslint-config-fluid/src/test/rules/no-markdown-links-in-jsdoc.test.js | Adds mocha tests for no-markdown-links-in-jsdoc. |
| common/build/eslint-config-fluid/src/test/rules/no-hyphen-after-jsdoc-tag.test.js | Adds mocha tests for no-hyphen-after-jsdoc-tag. |
| common/build/eslint-config-fluid/src/test/rules/no-file-path-links-in-jsdoc.test.js | Adds mocha tests for no-file-path-links-in-jsdoc. |
| common/build/eslint-config-fluid/src/test/rules/eslintConfigHelper.cjs | Updates test helper to load the local plugin shim. |
| common/build/eslint-config-fluid/src/test/fluid-rules.test.mts | Adds an integration test that runs custom rules through the exported flat config. |
| common/build/eslint-config-fluid/rules/tsdoc-utils.js | Adds shared TSDoc parsing helpers for multiple rules. |
| common/build/eslint-config-fluid/rules/no-unchecked-record-access.js | Adds the no-unchecked-record-access rule implementation into config package. |
| common/build/eslint-config-fluid/rules/no-restricted-tags-imports.js | Adds the no-restricted-tags-imports rule implementation into config package. |
| common/build/eslint-config-fluid/rules/no-member-release-tags.js | Adds the no-member-release-tags rule implementation into config package. |
| common/build/eslint-config-fluid/rules/no-markdown-links-in-jsdoc.js | Adds the no-markdown-links-in-jsdoc rule implementation into config package. |
| common/build/eslint-config-fluid/rules/no-hyphen-after-jsdoc-tag.js | Adds the no-hyphen-after-jsdoc-tag rule implementation into config package. |
| common/build/eslint-config-fluid/rules/no-file-path-links-in-jsdoc.js | Adds the no-file-path-links-in-jsdoc rule implementation into config package. |
| common/build/eslint-config-fluid/README.md | Documents that the config package now owns the custom rules. |
| common/build/eslint-config-fluid/pnpm-workspace.yaml | Removes plugin-related overrides/workarounds from this package workspace. |
| common/build/eslint-config-fluid/pnpm-lock.yaml | Updates lockfile to reflect moved rule dependencies. |
| common/build/eslint-config-fluid/package.json | Bumps version to 14.1.0 and moves rule deps into config package; updates test scripts for ESLint 8/9. |
| common/build/eslint-config-fluid/library/configs/base.mts | Switches from external plugin dependency to local fluidPlugin.cjs. |
| common/build/eslint-config-fluid/fluidPlugin.cjs | Adds plugin registration shim exporting the moved rules. |
| common/build/eslint-config-fluid/DEV.md | Adds updated development/publishing guide for consolidated rules. |
| common/build/eslint-config-fluid/CHANGELOG.md | Adds changelog entry describing consolidation in 14.1.0. |
| build-tools/packages/build-cli/src/test/filter.test.ts | Removes plugin package from build-cli filtering test expectations. |
| .syncpackrc.yml | Removes plugin package from shared version group. |
| .claude/skills/trigger-pipelines-for-copilot-pr/SKILL.md | Removes the deleted pipeline from the “trigger pipelines” guidance. |
| _buildProject.config.cjs | Removes plugin package release group definition. |
Files not reviewed (1)
- common/build/eslint-config-fluid/pnpm-lock.yaml: Generated file
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Keep only the removed eslint-plugin-fluid pipeline reference and restore the skill frontmatter unchanged. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: dd9688d7-f485-461a-9a13-1c3ef9f2322a
Import custom rules directly from src/rules, restore README generation, and keep test:mocha as the underlying Mocha command. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: dd9688d7-f485-461a-9a13-1c3ef9f2322a
Add a src/rules barrel that defines the Fluid plugin once for both the shared config and rule tests. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: dd9688d7-f485-461a-9a13-1c3ef9f2322a
Regenerate PACKAGES.md after removing eslint-plugin-fluid. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: dd9688d7-f485-461a-9a13-1c3ef9f2322a
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: dd9688d7-f485-461a-9a13-1c3ef9f2322a
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: dd9688d7-f485-461a-9a13-1c3ef9f2322a
|
While smoke-testing the packed
These failures come from the pre-existing 14.0 React-plugin upgrade and only surface when the client moves off config 13.x. They are not caused by consolidating |
Resolve the standalone eslint-config lockfile by regenerating it and keep the removed eslint-plugin pipeline deleted. Move custom rule tests beside their implementations under src/rules/test. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: dd9688d7-f485-461a-9a13-1c3ef9f2322a
Bundle size comparisonBase commit: Notable changesNo bundles changed by ≥ 500 bytes parsed. Per-bundle deltas
|
|
🔗 Found some broken links! 💔 Run a link check locally to find them. See Checking for Broken Links for more information. linkcheck output |
87506ad
into
microsoft:main
Description
Moves the custom Fluid ESLint rules into
@fluidframework/eslint-config-fluid, removing the separate@fluid-internal/eslint-plugin-fluidpackage and release pipeline. Existing@fluid-internal/fluid/*rule names are preserved, so consumers of the shared config do not need to migrate rule overrides or suppression comments.The config package is updated to 14.1.0 and now owns the rule dependencies, documentation, and ESLint 8/9 test coverage. Repository package metadata and pipeline-trigger guidance no longer reference the removed plugin.
Implements AB#79903.
Reviewer Guidance
The review process is outlined on this wiki page.
The npm deprecation of
@fluid-internal/eslint-plugin-fluidshould happen after@fluidframework/eslint-config-fluid14.1.0 is published.