Skip to content

Drop legacy ESLint config support - export flat config as main format - #527

Merged
ota-meshi merged 9 commits into
masterfrom
copilot/drop-legacy-config-support
Jan 17, 2026
Merged

ota-meshi merged 9 commits into
masterfrom
copilot/drop-legacy-config-support

Conversation

Copilot AI commented Jan 17, 2026 •

Copy link
Copy Markdown
Contributor

Drop support for legacy config - make flat config the main export

  • Understand current config structure and export format
  • Swap config implementations (flat configs become main, legacy configs removed)
  • Update src/index.ts to export the new structure
  • Update auto-generation script (tools/update-rulesets.ts)
  • Update README.md documentation
  • Update docs/user-guide/index.md documentation
  • Update tests to verify the new structure
  • Add changeset file describing the breaking change
  • Build and test the changes
  • Run final verification
  • Revert accidental change to docs/rules/index.md (should mention both recommended and standard configs)
  • Update rule documentation to reference new config format (configs.recommended, configs.standard)
  • Update docs/rules/index.md and tools/update-docs-rules-index.ts to use new config format

Summary

Successfully implemented the breaking change to drop legacy ESLint config support and make flat configuration the main export format.

Key changes:

  • Main config exports (base, recommended, standard, prettier) now use flat config format
  • flat/* namespace configs maintained for backward compatibility (point to same flat configs)
  • Removed legacy config files and associated test fixtures
  • Updated documentation to reflect new config format
  • Fixed accidental change to docs/rules/index.md - restored reference to both recommended and standard configs
  • Updated all rule documentation files to reference configs.recommended and configs.standard instead of legacy "plugin:yml/recommended" and "plugin:yml/standard" format
  • Updated docs/rules/index.md header to use new config format and corrected auto-generation comment

Migration:
Users on ESLint v9.38.0+ should update from configs['flat/recommended'] to configs.recommended (though flat/* still works for backward compatibility).

Original prompt

This section details on the original issue you should resolve

<issue_title>Drop support for legacy config</issue_title>
<issue_description>The plugin will change to export flat configuration as the main configuration format.
The previous flat/* namespace will be kept for backward compatibility.</issue_description>

<agent_instructions>Finally, add the changeset file</agent_instructions>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

@changeset-bot

changeset-bot Bot commented Jan 17, 2026 •

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: b9b3835

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
eslint-plugin-yml Major

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copilot AI and others added 2 commits January 17, 2026 01:30
Co-authored-by: ota-meshi <16508807+ota-meshi@users.noreply.github.com>
Co-authored-by: ota-meshi <16508807+ota-meshi@users.noreply.github.com>
Copilot AI changed the title [WIP] Remove support for legacy configuration format Drop legacy ESLint config support - export flat config as main format Jan 17, 2026
Copilot AI requested a review from ota-meshi January 17, 2026 01:47
Comment thread docs/rules/index.md Outdated
@github-actions

github-actions Bot commented Jan 17, 2026 •

Copy link
Copy Markdown
Contributor

Co-authored-by: ota-meshi <16508807+ota-meshi@users.noreply.github.com>

@ota-meshi ota-meshi left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

The explanations in the rules documents seem to be out of date. Please fix these as well.

Co-authored-by: ota-meshi <16508807+ota-meshi@users.noreply.github.com>

Copilot AI commented Jan 17, 2026

Copy link
Copy Markdown
Contributor Author

The explanations in the rules documents seem to be out of date. Please fix these as well.

Fixed in commit 75c4560. Updated tools/update-docs.ts to generate references to configs.recommended and configs.standard instead of the legacy "plugin:yml/recommended" and "plugin:yml/standard" format. All 23 rule documentation files have been regenerated with the new format.

Comment thread docs/rules/index.md Outdated
Comment thread tools/update-docs-rules-index.ts Outdated
Co-authored-by: ota-meshi <16508807+ota-meshi@users.noreply.github.com>
@ota-meshi
ota-meshi requested a review from Copilot January 17, 2026 02:10
@ota-meshi
ota-meshi marked this pull request as ready for review January 17, 2026 02:10
Copilot AI requested a review from ota-meshi January 17, 2026 02:10

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 implements a breaking change to drop support for legacy ESLint configuration format and make flat configuration the main export format. Users on ESLint v9+ can now use configs.recommended instead of configs['flat/recommended'], though the flat/* namespace is maintained for backward compatibility.

Changes:

  • Main config exports (base, recommended, standard, prettier) now directly export flat config format
  • Removed legacy config files and associated code/tests
  • Updated all documentation and rule references to use new config format

Reviewed changes

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

Show a summary per file
File Description
src/index.ts Updated to import flat configs as main exports, maintain flat/* for backward compatibility
src/configs/base.ts Removed legacy base config file
src/configs/recommended.ts Removed legacy recommended config file
src/configs/standard.ts Removed legacy standard config file
src/configs/prettier.ts Removed legacy prettier config file
tools/update-rulesets.ts Updated auto-generation script to only generate flat configs
tools/update-docs.ts Updated to reference new config format in documentation
tools/update-docs-rules-index.ts Updated rules index header to reference new config format
tests/src/eslint-plugin.ts Removed legacy config integration tests
tests/src/configs/standard.ts Updated to test new config format and verify backward compatibility
tests/fixtures/integrations/eslint-plugin/legacy-test01/* Removed legacy test fixtures
tests/fixtures/integrations/eslint-plugin/legacy-issue89/* Removed legacy test fixtures
README.md Updated documentation to show flat config as main format, removed legacy examples
docs/user-guide/index.md Updated user guide to show flat config as main format, removed legacy examples
docs/rules/index.md Updated header to reference configs.recommended and configs.standard
docs/rules/*.md Updated all rule documentation to reference new config format
.changeset/drop-legacy-config-support.md Added changeset documenting the breaking change

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@ota-meshi
ota-meshi merged commit 4059169 into master Jan 17, 2026
14 checks passed
@ota-meshi
ota-meshi deleted the copilot/drop-legacy-config-support branch January 17, 2026 02:14
@github-actions github-actions Bot mentioned this pull request Jan 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Drop support for legacy config

3 participants