cue
cue copied to clipboard
cuelang.org: broken CUE syntax highlighting
What page were you looking at?
https://cuelang.org/examples/cue/broken-highlighting/
What version of the site were you looking at?
https://github.com/cue-lang/cuelang.org/commit/d413e72e6437ff5569c0471398c32ce8dbf8917a
What did you do?
I published the linked page to the /examples hierarchy of the site.
What did you expect?
All CUE to be highlighted nicely.
What did you see instead?
Some CUE wasn't highlighted nicely.
Most recent rendered page: https://cl-1185745-2--cue-cls.netlify.app/examples/currently-broken-highlighting/
Most recent rendered page: https://cl-1185745-5--cue-cls.netlify.app/examples/currently-broken-highlighting/
Most recent rendered page: : https://cl-1185745-6--cue-cls.netlify.app/examples/currently-broken-highlighting/
Most recently rendered page: https://cl-1185745-7--cue-cls.netlify.app/examples/currently-broken-highlighting/
Most recently rendered page: https://cl-1185745-8--cue-cls.netlify.app/examples/currently-broken-highlighting/
FWIW I did not find this issue when filing https://github.com/cue-lang/cue/issues/3991 because of the lack of keywords, so: one of the issues here relates to empty comments being rendered as if they weren't comments.
FWIW I did not find this issue when filing #3991 because of the lack of keywords
Good point. Here are the current set of code comments I wrote on https://cuelang.org/examples/cue/broken-highlighting/ so they can be found in GitHub search:
// Comment markers without a trailing comment render wierdly.
// This will strike any guides where we import JSON Schema documents.
// Some types aren't highlighted the same as others
// Lots of non-ASCII characters are flagged as errors.
// Greek upper and lowercase:
// German sharp S
// Quotes inside other string forms break out of string highlighting
// Modified escape delimiters interact poorly with quotes inside strings
// Valid double-double-quotes forces the rest of the file to be rendered as if
// it were inside quotes.