vscode icon indicating copy to clipboard operation
vscode copied to clipboard

Cannot comment out JSX line

Open shalanah opened this issue 1 year ago • 1 comments

Type: Bug

JSX or TSX file try "command /" comment shortcut and nothing happens to a jsx line.

Commenting out regular TS/JS and even CSS seems fine.

(Tried insiders edition same issue)

VS Code version: Code 1.90.2 (Universal) (5437499feb04f7a586f677b155b039bc2b3669eb, 2024-06-18T22:37:41.291Z) OS version: Darwin arm64 23.5.0 Modes:

System Info
Item Value
CPUs Apple M3 Pro (12 x 2400)
GPU Status 2d_canvas: enabled
canvas_oop_rasterization: enabled_on
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_graphite: disabled_off
video_decode: enabled
video_encode: enabled
webgl: enabled
webgl2: enabled
webgpu: enabled
Load (avg) 4, 3, 3
Memory (System) 18.00GB (0.06GB free)
Process Argv --crash-reporter-id 7cb29e30-7206-4bc6-b247-ce1d34f725ca
Screen Reader no
VM 0%
Extensions (39)
Extension Author (truncated) Version
codesnap adp 1.3.4
preview-pdf ana 1.0.0
vscode-json and 1.5.2
vscode-styled-components-cre-edition Ant 1.3.0
vscode-color-picker Ant 0.0.4
arkademy-training ark 0.111.0
vscode-tailwindcss bra 0.12.2
npm-intellisense chr 1.4.5
path-intellisense chr 2.9.0
glsl-canvas cir 0.2.15
vscode-eslint dba 3.0.10
xml Dot 2.5.1
es7-react-js-snippets dsz 4.4.3
prettier-vscode esb 10.4.0
copilot Git 1.208.0
copilot-chat Git 0.16.1
todo-tree Gru 0.0.226
theme-macos-classic hua 1.7.1
npm ide 1.7.4
oneline-selection joe 1.0.1
rainbow-csv mec 3.12.0
template-string-converter meg 0.6.1
dotenv mik 1.0.1
vscode-typescript-next ms- 5.6.20240627
vscode-versionlens pfl 1.14.2
material-icon-theme PKi 5.4.2
html-to-jsx ria 0.0.1
preview-vscode sea 2.3.7
markdown-preview-enhanced shd 0.8.13
shader sle 1.1.5
code-spell-checker str 3.0.1
markdowntable Tak 0.11.0
es6-string-html Tob 2.15.0
sort-lines Tyr 1.11.0
vscode-mdx uni 1.8.9
gitblame wad 11.0.1
vscode-icons-mac way 7.25.3
pretty-ts-errors Yoa 0.5.4
sort-js-object-keys zen 1.0.6
A/B Experiments
vsliv368cf:30146710
vspor879:30202332
vspor708:30202333
vspor363:30204092
vscorecescf:30445987
vscod805:30301674
binariesv615:30325510
vsaa593cf:30376535
py29gd2263:31024239
c4g48928:30535728
azure-dev_surveyone:30548225
vscrp:30673768
2i9eh265:30646982
962ge761:30959799
pythongtdpath:30769146
welcomedialog:30910333
pythonnoceb:30805159
asynctok:30898717
pythonregdiag2:30936856
pythonmypyd1:30879173
h48ei257:31000450
pythontbext0:30879054
accentitlementst:30995554
dsvsc016:30899300
dsvsc017:30899301
dsvsc018:30899302
cppperfnew:31000557
dsvsc020:30976470
pythonait:31006305
jchc7451:31067544
chatpanelc:31048052
dsvsc021:30996838
f3je6385:31013174
pythoncenvpt:31062603
a69g1124:31058053
dvdeprecation:31068756
dwnewjupytercf:31046870
legacy_priority:31082724

shalanah avatar Jun 28 '24 20:06 shalanah

Weirdly enough if I add some more JSX then commenting out starts working again:

Open file:

<>
  <Modals />
</>

Commenting out doesn't work then I add

<>
  <Modals />
  <h1 />
</>

Commenting works again.

shalanah avatar Jun 28 '24 20:06 shalanah

Works fine for me. I suspect one of your extensions is causing this

mjbvz avatar Jul 02 '24 18:07 mjbvz

On that day, I also downloaded VSCode Insiders and replicated there with no extensions, but today everything is working fine on both too so 🤷‍♀️ .

shalanah avatar Jul 02 '24 18:07 shalanah