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

HTML folding does not work inside a <script> tag #116652

Closed
TotallyInformation opened this issue Feb 14, 2021 · 2 comments
Closed

HTML folding does not work inside a <script> tag #116652

TotallyInformation opened this issue Feb 14, 2021 · 2 comments
Assignees

Comments

@TotallyInformation
Copy link

TotallyInformation commented Feb 14, 2021

  • VS Code Version: 1.53.2
  • OS Version: Windows 10 (latest)

Steps to Reproduce:

  1. Create a .html file
  2. Set VScode folding strategy to "auto"
  3. Write valid html with a <script type="text/html"> section (which is valid HTML)
  4. Include valid, nested html inside the script section

Does this issue occur when all extensions are disabled?: Yes

Note that region folding is also disabled in this case.

Example screenshots:

image


A followup question would be - why is the folding strategy only auto or indent? Why can't it be both? Which would fix this issue and also the annoying JSDoc folding issue in JavaScript files.

@aeschli
Copy link
Contributor

aeschli commented Feb 22, 2021

We have folding in <script> but only when the type is JavaScript.

Support for text/html is #77977

@TotallyInformation
Copy link
Author

Thanks for the response, looks like there is a PR already in place so I assume that will flow through to the live version in time. If it still isn't working in a few months, I'll raise a new issue.

@github-actions github-actions bot locked and limited conversation to collaborators Apr 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants