Skip to content

Yaml highlights have extra space #94

@amshkv

Description

@amshkv

Describe the bug
When using the line-number-plugin yaml highlights, multilines have an extra space
without line-numbers all aligned to the left edge

To Reproduce
https://codepen.io/Keda37/pen/ExRddRR - on/off hljs.initLineNumbersOnLoad();

Screenshots
Снимок экрана 2022-12-02 в 13 08 59
image

Activity

wcoder

wcoder commented on Dec 2, 2022

@wcoder
Owner

Thanks for the report!

Looks like plugin generates extra tags:
Screen Shot 2022-12-02 at 7 09 35 PM

Workaround

Add more line breaks:

<pre><code class="language-yaml hljs">
multiline_1: |
  Multiline
  String

multiline_2: |
  Multiline
  String

multiline_3: |
  Multiline
  String

multiline_1:
  - Multiline
  - Multilne

multiline_2: Multiline
multiline_3: Multiline
</code></pre>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Yaml highlights have extra space · Issue #94 · wcoder/highlightjs-line-numbers.js