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

ERB support seems to have disabled HTML folding #2394

Closed
Intrepidd opened this issue Jul 31, 2024 · 8 comments · Fixed by #2398
Closed

ERB support seems to have disabled HTML folding #2394

Intrepidd opened this issue Jul 31, 2024 · 8 comments · Fixed by #2398
Assignees
Labels
bug Something isn't working

Comments

@Intrepidd
Copy link

Intrepidd commented Jul 31, 2024

Before erb support was added, it was possible to fold HTML tags in erb files

Since erb support, only ruby expressions are foldable.
Disabling erb support reverts the behaviour as expected.

It would be amazing to be able to fold both ruby expressions and HTML tags with Ruby LSP

@Intrepidd Intrepidd added the bug Something isn't working label Jul 31, 2024
@DanudeSandstorm
Copy link

I reverted back to 0.7.10 to stop seeing errors in my erb

@andyw8
Copy link
Contributor

andyw8 commented Jul 31, 2024

Thanks, I expect this relates to something in #2235 but we'll need to investigate further.

cc @st0012

@andyw8 andyw8 assigned andyw8 and unassigned vinistock Jul 31, 2024
@st0012
Copy link
Member

st0012 commented Jul 31, 2024

I can reproduce this and am investigating it 👍

@st0012 st0012 assigned st0012 and unassigned andyw8 Jul 31, 2024
@st0012
Copy link
Member

st0012 commented Jul 31, 2024

Based on these discussions:

It looks like VS Code doesn't support multiple folding range providers on the same type of file. So the only way to solve this issue is to tell VS Code to NOT use Ruby LSP's folding range when the file is erb or rhtml.

@Intrepidd
Copy link
Author

So the only way to solve this issue is to tell VS Code to NOT use Ruby LSP's folding range when the file is erb or rhtml.

Is there a way to do that through config?

@Alex808r
Copy link

Alex808r commented Aug 1, 2024

I reverted back to 0.7.10 to stop seeing errors in my erb

it is work for me too, thx!

@st0012
Copy link
Member

st0012 commented Aug 1, 2024

Is there a way to do that through config?

Do you mean switching between Ruby folding and HTML folding?

@Intrepidd
Copy link
Author

yes, I guess that could be useful, although in my case I would take the HTML folding over erb folding almost every time

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants