question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Prettier 2.3.0 appears incompatible with prettier-plugin-eex

See original GitHub issue

I recently upgraded a project from prettier 2.2.1 to 2.3.0 and when I did that all my eex files were reformatted. Reverting back to 2.2.1 from 2.3.0 gets everything to work again.

I’ve tested with 0.5.0 and 1.11.4 otp23 and otp24. All produce the same eext1 most elixir content in eex files.

I suspect that #43 is failing all the CI checks for the same problems and likely #50 is the same since the versions match. The work around for me was to downgrade to prettier 2.2.1 and npm install and formatting worked again.

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:1
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

3reactions
adamzapasnikcommented, May 16, 2021

hey @elliottneilclark Thanks for submitting the issue. Yes, the problem is related to the new prettier version. For now you have to keep 2.2.x. Sorry for the trouble.

0reactions
arashoutcommented, Nov 14, 2021

I have the same issue. Installed prettier through npm npm install prettier prettier-plugin-eex My package.lock

{
  "requires": true,
  "lockfileVersion": 1,
  "dependencies": {
    "prettier": {
      "version": "2.4.1",
      "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.4.1.tgz",
      "integrity": "sha512-9fbDAXSBcc6Bs1mZrDYb3XKzDLm4EXXL9sC1LqKP5rZkT6KRr/rf9amVUcODVXgguK/isJz0d0hP72WeaKWsvA=="
    },
    "prettier-html-templates": {
      "version": "0.1.0",
      "resolved": "https://registry.npmjs.org/prettier-html-templates/-/prettier-html-templates-0.1.0.tgz",
      "integrity": "sha512-KdLveYzO2kJLiwUAebd5UFeKP8h3OqFhOiLbkgeIuS1WNoCRTyxW4KuyGfbh3F+Rp/2A6mipRxCq2zPi+//pmg=="
    },
    "prettier-plugin-eex": {
      "version": "0.5.0",
      "resolved": "https://registry.npmjs.org/prettier-plugin-eex/-/prettier-plugin-eex-0.5.0.tgz",
      "integrity": "sha512-2XJOnvg/wk0GkNscOyjom9uC1H5s7iX8vJVtMwL8eoVYd1CTf6/sy+9D02EZB1pixf2ilIvtu1sPECEQZgn4Fw==",
      "requires": {
        "prettier-html-templates": "^0.1.0"
      }
    }
  }
}
Read more comments on GitHub >

github_iconTop Results From Across the Web

Incompatibility with other Prettier plugins · Issue #31 - GitHub
This means this plugin is incompatible with other Prettier plugins that are using the same APIs. This GitHub issue will serve as a...
Read more >
Prettier 2.3. In which assignments are consistent, short keys ...
This means Prettier won't format Handlebars files that can't be parsed into such a tree, either because the underlying syntax isn't HTML or ......
Read more >
ESLint with Prettier issues on Yarn global install - Stack Overflow
I just ran into the same issue myself. It appears to be an issue with the newest version of eslint, mine was 4.2.0....
Read more >
Prettier plugin does not format *.svelte files, even ... - YouTrack
I've double-checked that the request to format svelte file is sent correctly but Prettier service responds that the file is unsupported. You'll see...
Read more >
Formatting *.html.eex *.html.leex *.html.heex files - Elixir Forum
Prettier 2.3.0 appears incompatible with prettier -plugin-eex. opened 05:55AM - 16 May 21 UTC. elliottneilclark.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found