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

Razor syntax not highlighting #21

Open
dush-a opened this issue Feb 16, 2023 · 1 comment
Open

Razor syntax not highlighting #21

dush-a opened this issue Feb 16, 2023 · 1 comment

Comments

@dush-a
Copy link

dush-a commented Feb 16, 2023

I used the Static website or simple usage explained on the readme page.

<script type="text/javascript" src="/path/to/highlight.min.js"></script>
<script type="text/javascript" src="/path/to/highlightjs-cshtml-razor/dist/cshtml-razor.min.js"></script>
<script>
    hljs.highlightAll();
</script>

Then how can I use it on an HTML page?

I tried the following:

<pre><code class="language-cshtml"> cshtml here </code></pre>
didn't work, then tried

<pre><code class="language-cshtml-razor"> cshtml here </code></pre>
no luck.

Thanks

@joshgoebel
Copy link
Member

Should work, are you seeing an error in console? Are you loading a CSS theme? What makes you think it's not working?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants