Giter Club home page Giter Club logo

Comments (7)

kachkaev avatar kachkaev commented on June 9, 2024 2

I updated instructions for now: 56c32ae.

@jwoLondon feel free to improve them if you see any opportunities.

from prettier-plugin-elm.

kachkaev avatar kachkaev commented on June 9, 2024

👋 @kantuni! Which version of Prettier are you using? Can you please provide reproduction steps?

For the plugin to work in VS Code, it is necessary to list it in the Prettier’s config file: https://prettier.io/docs/en/plugins.html. E.g. in .prettierrc.json:

{
  "plugins": ["prettier-plugin-foo"]
}

from prettier-plugin-elm.

jwoLondon avatar jwoLondon commented on June 9, 2024

Could it be related to the problems with Prettier in vsCode since V9.16?

prettier/prettier-vscode#3045

from prettier-plugin-elm.

kachkaev avatar kachkaev commented on June 9, 2024

Prettier 3.0 has dropped support for automatic plugin search because it had a lot of hard-to-solve issues (prettier/prettier#14759). Prettier plugins are is usually installed locally and are declared in Prettier config file. This file is located at the root of the project folder.

How difficult would be to change our recommended setup flow to a local copy of Prettier? If we cannot do that, we can stick with Prettier v2 or ask editor maintainers to support global plugins somehow.

from prettier-plugin-elm.

kantuni avatar kantuni commented on June 9, 2024

The issue was caused by Prettier v3. After downgrading to v2, everything works smoothly.
Thank you!

from prettier-plugin-elm.

kachkaev avatar kachkaev commented on June 9, 2024

Hmm, that’s odd. What was the context in which your were getting this error? This repo runs tests against Prettier v1, v2 and v3, so I it’d be great if you could help with the reproduction.

If anyone else experiences issues with prettier-plugin-elm after upgrading to Prettier v3, please give us a shout and we will reopen this issue!

from prettier-plugin-elm.

kantuni avatar kantuni commented on June 9, 2024

Hey @kachkaev 👋 ,

Sorry for a late response. I just saw this message.

I'm trying to setup prettier-plugin-elm with prettier-plugin-tailwindcss (which requires Prettier v3).
But no matter what I do, VS Code refuses to show Prettier as a formatter for Elm files.

Happy to help repro!

from prettier-plugin-elm.

Related Issues (9)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.