nuxt / content

The file-based CMS for your Nuxt application, powered by Markdown and Vue components.
https://content.nuxt.com
MIT License
3.08k stars 624 forks source link

Syntax highlighting does not work in windows #2522

Closed TheMrMilchmann closed 2 months ago

TheMrMilchmann commented 8 months ago

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:  yarn@1.22.21
- Builder:          -
- User Config:      srcDir, app, content, modules, typescript
- Runtime Modules:  @nuxt/content@2.11.0
- 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

pi0 commented 8 months ago

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
TheMrMilchmann commented 8 months ago

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

github-actions[bot] commented 2 months ago

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.

TheMrMilchmann commented 2 months ago

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.