prettier-plugin-erb icon indicating copy to clipboard operation
prettier-plugin-erb copied to clipboard

<% %> Delete

Open PoLePanda opened this issue 3 years ago • 7 comments

All my ruby tag <% %> are delete or replace with <eext1 /> <eext2 /> <eext3 />...

I don't know what i'm doing wrong

package.json:

"devDependencies": {
    "@prettier/plugin-ruby": "^1.6.1",
    "prettier-plugin-erb": "^0.4.0",
    "prettier": "^2.3.2",
}

.prettierrc.json:

{
  "[ruby]": {
    "editor.defaultFormatter": "esbenp.prettier-vscode",
    "editor.formatOnSave": true
  },
  "[erb]": {
    "editor.defaultFormatter": "esbenp.prettier-vscode",
    "editor.formatOnSave": true
  }
}

vscode settings.json

"files.associations": {
  "*.js": "javascriptreact",
  "*.html.erb": "erb"
},
"emmet.includeLanguages": {
  "erb": "html",
  "ruby": "html",
  "javascript": "javascriptreact"
},
"ruby.format": "prettier"

PoLePanda avatar Aug 11 '21 18:08 PoLePanda

@adamzapasnik Any updates on this issue?

jalajcodes avatar Sep 07 '21 11:09 jalajcodes

@adamzapasnik Any updates on this issue?

Nope 0 updates ...

PoLePanda avatar Sep 07 '21 16:09 PoLePanda

Sorry guys, you need to use [email protected] 2.3 and above don't work currently

adamzapasnik avatar Sep 07 '21 19:09 adamzapasnik

Sorry guys, you need to use [email protected] 2.3 and above don't work currently

Tried with 2.2 but same problem🙁

jalajcodes avatar Sep 08 '21 01:09 jalajcodes

Sorry guys, you need to use [email protected] 2.3 and above don't work currently

Tried with 2.2 but same problem

does it affect all tags or just a few ones? @jalajcodes

adamzapasnik avatar Sep 08 '21 15:09 adamzapasnik

Sorry guys, you need to use [email protected] 2.3 and above don't work currently

Tried with 2.2 but same problem

does it affect all tags or just a few ones? @jalajcodes

all tags gets converted

jalajcodes avatar Sep 08 '21 15:09 jalajcodes

~~I'm still seeing this issue right now w/ prettier 1.6.1~~

Never mind, using the following package versions got it working for me.

{
  "devDependencies": {
    "@prettier/plugin-ruby": "1.6.1",
    "prettier": "2.2.1",
    "prettier-plugin-erb": "^0.4.0"
  }
}

PelagicDev avatar Dec 22 '21 20:12 PelagicDev