microsoft / microsoft/monaco-editor

[Bug] No syntax highlighting for JSDoc any longer

Open
#4,369 5 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug confirmed
Dominant language
JavaScript
Stars
46.8k
Forks
4.1k
Avg merge
17h 58m
Merged PRs (30d)
1

Description

Reproducible in vscode.dev or in VS Code Desktop?
  • Not reproducible in vscode.dev or VS Code Desktop
Reproducible in the monaco editor playground?
Monaco Editor Playground Link

https://microsoft.github.io/monaco-editor/playground.html?source=v0.45.0#XQAAAAK1AwAAAAAAAABBqQkHQ5NjdMjwa-jY7SIQ9S7DNlzs5W-mwj0fe1ZCDRFc9ws9XQE0SJE1jc2VKxhaLFIw9vEWSxW3yscw4pIQW-D--FtoY2uhtnt5ekkHMF9tBxoQ1uluHZgysFLW8kM8-2qiygUAoo99NHysljdDNmCJYaB8CZbAvLf7uYFliPg2fjRLv__l9_zeGRBrBXHI1Kkt9FeoBUqFliemCUPmzZgVmq590GESmmD0SQHL-0fTut3B3E6_V0x8CkDF08OHY4mFhdjFJGafs4KB5Dm7L-6nVepYQT4voko79FYpnuUqyKEofn8CYZ_avsEABp8UFz9qikKat9aRAVQyRlP_n6MM1sGs6RSc5Pq_ktTI-EDiEHfW15eG0_7xycpgq1nIVj0g7Tyoa12_pxXQaMLYNqnw5eVJnz8C9csuHwEEwzxyUTMoepgXqYCgvZ162TowWJw2ilBq06kT84AR7GobBeoJUEIdsxmpM3b34QMdOBtmT6n_EGUx_UG4DWHMRvcR0dCEcU_vYAsPa7mHivqmETVLqc43EPb_c0mXAA

Monaco Editor Playground Code
/**
 * @template {Record<string, string>} [FILES=Record<string, string>]
 * @typedef {object} ExampleOptions
 * @property {HTMLCanvasElement} canvas - The canvas.
 * @property {string} deviceType - The device type.
 * @property {string} assetPath - The asset path.
 * @property {string} scriptsPath - The scripts path.
 * @property {string} glslangPath - The glslang path.
 * @property {string} twgslPath - The twgsl path.
 * @property {string} dracoPath - The draco path.
 * @property {string} ammoPath - The ammo path.
 * @property {string} basisPath - The basis path.
 * @property {any} pcx - The pcx.
 * @property {FILES} files - The files.
 */

/**
 * @typedef {{ 'shader.vert': string, 'shader.frag': string }} Files
 * @typedef {ExampleOptions<Files>} Options
 * @param {Options} options - The example options.
 * @returns {Promise<pc.AppBase>} The example application.
 */
Reproduction Steps
  1. Just open
  2. See no colors
Actual (Problematic) Behavior

Missing colors:

image

Expected Behavior

Colored comments:

image

Additional Context

It always used to work, suddenly colors are gone (also on TS Playground).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the linked Monaco Editor Playground reproduction and its embedded TypeScript/JSDoc sample, then compare the missing colors with the expected screenshot and the behavior in the TypeScript Playground. Trace the syntax-highlighting entry point used for JSDoc comments. Done means the documented tags and types render with syntax colors again in the playground and desktop editor.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, typescript
Domain
frontend, tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.