Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not highlighting correctly #105

Open
alvarotrigo opened this issue Mar 25, 2023 · 0 comments
Open

Not highlighting correctly #105

alvarotrigo opened this issue Mar 25, 2023 · 0 comments
Labels
outdated languages The language definition is likely outdated from upstream

Comments

@alvarotrigo
Copy link

alvarotrigo commented Mar 25, 2023

I posted this issue originally on the the highlight.js repository but I guess the problem is on this port rather than on the JS library itself:
highlightjs/highlight.js#3743

Describe the issue

Having something like this:

  const optionToSelect = $options.find(item => item.text ===text);

The whole optionToSelect = $options.find( gets the same color without separating the find function.
I'm not using auto-detection.

Picture:
image

image

Here's the right coloring using the latest version of the JS component highlight.js. Notice the "find" gets colored.
https://jsfiddle.net/chy5nd72/

Sample Code to Reproduce

This is how jsfiddle shows it:
image

This is how Prism.js shows it:
image

Expected behavior
It should look more like this:
image

image

@allejo allejo added bug needs investigation Some further investigation is needed outdated languages The language definition is likely outdated from upstream and removed needs investigation Some further investigation is needed bug labels May 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
outdated languages The language definition is likely outdated from upstream
Projects
None yet
Development

No branches or pull requests

2 participants