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

Format selection does not consider dprint a valid formatter #60

Open
GNRSN opened this issue Jun 12, 2023 · 0 comments
Open

Format selection does not consider dprint a valid formatter #60

GNRSN opened this issue Jun 12, 2023 · 0 comments

Comments

@GNRSN
Copy link

GNRSN commented Jun 12, 2023

Hi, just started exploring dprint and tried this extension, formatting the document works fine but when I try to format a selection VScode complains about dprint not being a valid formatter for [current file type].

I could not understand if this was a limitation with the extension(/dprint) or a bug?

Minimal repro:

  • Create a new folder
  • Init dprint with default settings
  • add newlines at top of dprint.json
  • > Format document works as exepcted
  • highlighting the newlines and selecting > Format selection (cmd+k cmd+f) throws in VScode with error:

"Extension 'Dprint Code Formatter' is configured as formatter but it cannot format 'JSON'-files"

My setup:
dprint: 0.37.1 (homebrew install)
VScode: 1.79.0
dprint.dprint extension: v0.14.0

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

1 participant