Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proposal to rename "quickfix.biome" to "source.fixAll.biome" #3339

Open
predragnikolic opened this issue Jul 2, 2024 · 2 comments
Open

Proposal to rename "quickfix.biome" to "source.fixAll.biome" #3339

predragnikolic opened this issue Jul 2, 2024 · 2 comments

Comments

@predragnikolic
Copy link

predragnikolic commented Jul 2, 2024

Description

Hello,

Currently biome exposes a "quickfix.biome" code action on save. (see the docs)
The proposal is to rename quickfix.biome to source.fixAll.biome because it adheres to the LSP spec more:

microsoft/language-server-protocol#1629 (comment)

For code actions on save: the client will ask with a specific kind for code actions on save. The kind is CodeActionKind.SourceFixAll

export namespace CodeActionKind {
	export const Empty: CodeActionKind = '';

	/**
	 * Base kind for quickfix actions: 'quickfix'.
	 */
	export const QuickFix: CodeActionKind = 'quickfix';

	// ...
	/**
	 * Base kind for a 'fix all' source action: `source.fixAll`.
	 *
	 * 'Fix all' actions automatically fix errors that have a clear fix that
	 * do not require user input. They should not suppress errors or perform
	 * unsafe fixes such as generating new types or classes.
	 *
	 * @since 3.17.0
	 */
	export const SourceFixAll: CodeActionKind = 'source.fixAll';
}

Related issues:
sublimelsp/LSP#2495

@ematipico
Copy link
Member

That's definitely a sound proposal. I wouldn't change it right away because it would break people's code.

We can add it, deprecate the current when, and remove it in V2. How does that sound?

@predragnikolic
Copy link
Author

@ematipico yes, sounds good. Not breaking anyone workflow is a good option.

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

No branches or pull requests

2 participants