-
Notifications
You must be signed in to change notification settings - Fork 28
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
Highlight.js Vue Plugin systematically ignores language value passed to it #49
Comments
What languages do you usually see getting chosen? |
@joshgoebel Javascript and HTML (ideally Vue component too but I don't think that package supports that). |
Maybe add some debugging to output the value of |
I ran into the same problem The solution is to pass I found the solution by reading the source code for 1 minute 🤣 |
It looks to me (reading source) that setting language should override the autodetect prop, am I missing something? |
Whether I call the plugin directly from my template section or mount it programmatically and passing to it a language prop value, the language I specify always ends up being ignored by the plugin who instead chooses himself a language.
From template section:
<highlightjs language='javascript' code="var x = 5;" />
From script section (programmatically):
Here's how the plugin is imported in my main.js:
The text was updated successfully, but these errors were encountered: