content icon indicating copy to clipboard operation
content copied to clipboard

Syntax highlighting does not work in windows

Open TheMrMilchmann opened this issue 7 months ago • 2 comments

Environment

------------------------------
- Operating System: Windows_NT
- Node Version:     v18.12.1
- Nuxt Version:     3.9.3
- CLI Version:      3.10.0
- Nitro Version:    2.8.1
- Package Manager:  [email protected]
- Builder:          -
- User Config:      srcDir, app, content, modules, typescript
- Runtime Modules:  @nuxt/[email protected]
- Build Modules:    -
------------------------------

Reproduction

See https://github.com/TheMrMilchmann/MCVE/tree/nuxt/content/2522-syntax-highlighting for an MCVE.

Describe the bug

When running in development mode (via nuxi dev) there is no syntax highlighting. However, when previewing the build outputs (nuxi build and nuxi preview), it works as expected.

This change was introduced by the update to 3.11.0. With 3.10, I cannot reproduce this issue.

Additional context

I believe it could be related to #2520.

Logs

No response

TheMrMilchmann avatar Jan 24 '24 11:01 TheMrMilchmann

Thanks for making reproduction. Checking locally, i do have syntax highlighting in development mode. But I am on MacOS. Do you have a chance to try with WSL2 or Linux/MacOS machine? I am suspicious it might be a platform-specific issue.

image

pi0 avatar Jan 24 '24 15:01 pi0

Syntax highlighting works fine when running in WSL, but I can consistently reproduce it on "plain" Windows. Looks like this is indeed platform-specific.

TheMrMilchmann avatar Jan 24 '24 16:01 TheMrMilchmann

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 30 days.

github-actions[bot] avatar Jul 18 '24 15:07 github-actions[bot]

I'm unsure when this was fixed (and I don't feel like bisecting the change), but I cannot reproduce this anymore on >=2.13. I'll close this for now.

TheMrMilchmann avatar Jul 18 '24 16:07 TheMrMilchmann