question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

hl_lines is not supported anymore

See original GitHub issue

With zmarkdown, when we want to use hl_lines on source codes, the render to rehype is not properly parsed.

the markdown

what we get

        <div class="hljs-code-div"><div class="hljs-line-numbers"><span></span><span></span><span></span><span></span></div><pre><code class="hljs language-python">a = <span class="hljs-number">2</span>
b = a + <span class="hljs-number">5</span>
c = a + b
print(a, b, c)
</code></pre></div>

what we expect :

something that wraps line 3 (and all lines that are specified) so that css can color it. For example, it can be

        <div class="hljs-code-div"><div class="hljs-line-numbers"><span></span><span></span><span></span><span></span></div><pre><code class="hljs language-python">a = <span class="hljs-number">2</span>
b = a + <span class="hljs-number">5</span>
<span class="hljs-highlight">c = a + b</span>
print(a, b, c)
</code></pre></div>

Nota : here are the supported syntax to specify lines :

hl_lines=3 // only line 3 will be highlighted
hl_lines=3,4 // line 3 and line 4
hl_lines=3-8 // line 3 to 8
hl_lines=3,5-8,15 // line 3, lines 5 to 8, line 15 will be highlighted

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
TRSasasusucommented, Feb 24, 2019

Today, I made a plugin highlighting specific lines. https://github.com/TRSasasusu/highlightjs-highlight-lines.js

0reactions
StaloneLabcommented, Sep 5, 2020

Since this is now done, I think it can be closed!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error message: There's no line here to end - TeX
Empty lines above and below the opening caused the error. ... because TeX will not switch to horizontal mode (it will stay in...
Read more >
XCode 14.0 comment shortcut not working anymore
XCode 14.0 comment shortcut not working anymore. You're now watching this thread ... Previously using ( ⌘ + / ) to comment a...
Read more >
Pyplot hlines and vlines do not use the 'lines.color ... - GitHub
Bug report Bug summary hlines and vlines color does not default to lines.color in rcParams. The default argument is 'k' which doesn't work ......
Read more >
matplotlib.pyplot.hlines — Matplotlib 3.6.2 documentation
Plot horizontal lines at each y from xmin to xmax. Parameters: yfloat or array-like ... If scalars are provided, all lines will have...
Read more >
When I edit the code in a TextArea using CodeMirror how to ...
... you don't pass an onChange option anymore to register a change handler, ... onChange handling in code mirror is not like this...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found