Vscode: JSX: Collapse icons are disappear

Created on 7 Jun 2018  路  7Comments  路  Source: microsoft/vscode

  • VSCode Version 1.24.0 (1.24.0)
  • OS Version: MacOS 10.13.4

Steps to Reproduce:

screen shot 2018-06-06 at 6 06 05 pm


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

*duplicate javascript typescript

Most helpful comment

Solution from another issue: "typescript.experimental.syntaxFolding": false

All 7 comments

This was never officially supported, see https://code.visualstudio.com/updates/v1_24#_syntax-aware-folding-enabled-by-default-for-jsts

Syntax aware support for this is tracked by https://github.com/Microsoft/TypeScript/issues/23273

I have never had this error in previous version @@
Now I had

It only worked because it happened to be indented (which is how all folding used to work). If you had the code:

const a = <div>
<a>
</a>
</div>

You'll notice the folding never worked because it lacks indentation. Syntax based folding will let us fix that

Solution from another issue: "typescript.experimental.syntaxFolding": false

Unfortunately release 1.25 took away the "typescript.experimental.syntaxFolding": false setting change solution and kept the non-working folding :(

It will display the folding markers briefly in the window upon first loading of vscode but then they disappear and do not reappear.

Ok, noted that it will remove the folding tics as soon as the OUTLINE section populates.

Replace

"typescript.experimental.syntaxFolding": false

with

"[javascript]": {
  "editor.foldingStrategy": "indentation"
},
"[javascriptreact]": {
  "editor.foldingStrategy": "indentation"
},
"[typescript]": {
  "editor.foldingStrategy": "indentation"
},
"[typescriptreact]": {
  "editor.foldingStrategy": "indentation"
}

This one also resolving the issue
"editor.foldingStrategy": "indentation"

Was this page helpful?
0 / 5 - 0 ratings

Related issues

villiv picture villiv  路  3Comments

trstringer picture trstringer  路  3Comments

chrisdias picture chrisdias  路  3Comments

sijad picture sijad  路  3Comments

lukehoban picture lukehoban  路  3Comments