Skip to content

Migrate to Prettier v3 #317

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

Closed
sosukesuzuki opened this issue Oct 18, 2022 · 16 comments
Closed

Migrate to Prettier v3 #317

sosukesuzuki opened this issue Oct 18, 2022 · 16 comments
Labels
dependencies Pull requests that update a dependency file enhancement New feature or request

Comments

@sosukesuzuki
Copy link

Hi, I am a maintainer at Prettier.

The Prettier team is currently working on v3(still alpha).
v3 will include breaking changes to the plugin interface.
Please see https://github.com/prettier/prettier/releases/tag/3.0.0-alpha.2 for more information.

I created this issue to help major plugins migrate to Prettier v3.

Myself and @fisker have created a migration guide which you can see here:

https://github.com/prettier/prettier/wiki/How-to-migrate-my-plugin-to-support-Prettier-v3%3F

If you have any questions, feel free to mention us. We can help you.

If you have already migrated to Prettier v3, sorry but please close this issue.

@dummdidumm dummdidumm added enhancement New feature or request dependencies Pull requests that update a dependency file labels Oct 18, 2022
@carmanchris31
Copy link
Contributor

carmanchris31 commented Dec 4, 2022

Thanks @sosukesuzuki! Are there any plans for prettier to start publishing types for the api?

@sosukesuzuki
Copy link
Author

We have @types/prettier. But it doesn't support 3.x...

@carmanchris31
Copy link
Contributor

Are there plans for prettier to update the types there? Or should we look into it?

@carmanchris31
Copy link
Contributor

I've started working on this and will post a PR when I've got the tests passing again. Can we also make a next branch for the v3 changes?

@sosukesuzuki
Copy link
Author

Are there plans for prettier to update the types there? Or should we look into it?

Sorry, Prettier core team doesn't maintain @types/prettier.

@carmanchris31
Copy link
Contributor

@prettier/plugin-pug is migrating here: prettier/plugin-pug#411

@potykion

This comment was marked as spam.

@dummdidumm dummdidumm pinned this issue Jul 5, 2023
@sebastinez
Copy link

sebastinez commented Jul 5, 2023

Is this something that is being worked on? Would you be ok with receiving a PR for this issue?

@dummdidumm
Copy link
Member

#365 is the current PR for this. The plan is to pick it up this or next week. Help is welcome!

@carmanchris31
Copy link
Contributor

carmanchris31 commented Jul 5, 2023

Is this something that is being worked on? Would you be ok with receiving a PR for this issue?

Yes this is a work in progress (there is a draft PR at #365) but we need help to move it along. Maybe you could coordinate with @dummdidumm who also volunteered to help?

@sebastinez
Copy link

#365 is the current PR for this. The plan is to pick it up this or next week. Help is welcome!

Nice will give it a look and help where I can

@dummdidumm
Copy link
Member

Note to self: When we integrate the new major version of prettier-plugin-svelte which only works for Prettier 3, we have to add additional checks in the VS Code extension since to ensure we're not loading incompatible combinations of Prettier and the Svelte plugin.

@TristanBrotherton
Copy link

Is this still in the works? We recently migrated to prettier v3 and I'm now having trouble getting VsCode to format svelte files on save. Not sure if the issue lies here or in the vscode extension.

@PuruVJ
Copy link

PuruVJ commented Jul 19, 2023

The PRs are merged, although it is unreleased as of yet https://github.com/sveltejs/prettier-plugin-svelte/blob/master/CHANGELOG.md

@TristanBrotherton
Copy link

Thank you for the reply, that's very helpful. I'm guessing when the vscode plug-in is updated after release it will resolve the issue.

@dummdidumm
Copy link
Member

Version 3 of this plugin has been released with Prettier v3 support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

7 participants