Skip to content

Conversation

@rzzf
Copy link
Contributor

@rzzf rzzf commented Dec 6, 2025

resolves #2666

@changeset-bot
Copy link

changeset-bot bot commented Dec 6, 2025

🦋 Changeset detected

Latest commit: 7b93db3

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-vue Minor

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

Copy link
Member

@FloEdelmann FloEdelmann left a comment

Choose a reason for hiding this comment

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

Looks good to me, thank you! 🙂

Copy link
Contributor

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 adds a new ignoreEOLComments option to the vue/no-multi-spaces rule, allowing users to preserve multiple spaces before end-of-line comments for alignment purposes. When enabled, the rule will ignore multiple spaces that appear before line comments (//) or block comments (/* */) at the end of a line.

Key Changes

  • Added ignoreEOLComments boolean option to the rule schema with a default value of false
  • Implemented logic to detect comments at the end of lines and conditionally ignore spaces before them
  • Added test cases demonstrating both valid and invalid usage with the new option

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
lib/rules/no-multi-spaces.js Added schema property and implementation logic to detect and ignore spaces before EOL comments when the option is enabled
tests/lib/rules/no-multi-spaces.js Added valid test cases showing comments with multiple spaces when ignoreEOLComments: true, and invalid test cases showing they're flagged when ignoreEOLComments: false
docs/rules/no-multi-spaces.md Added documentation for the new option with usage examples showing alignment of comments
.changeset/swift-spies-nail.md Added changeset entry documenting this as a minor version feature addition

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

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.

vue/no-multi-spaces and global no-multi-spaces settings inconsistency

2 participants