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

Markdown code blocks renders a extra line #12515

Open
1 task done
GrimLink opened this issue Nov 24, 2024 · 0 comments
Open
1 task done

Markdown code blocks renders a extra line #12515

GrimLink opened this issue Nov 24, 2024 · 0 comments
Labels
needs triage Issue needs to be triaged

Comments

@GrimLink
Copy link

Astro Info

Astro                    v4.16.14
Node                     v20.5.1
System                   macOS (x64)
Package Manager          npm
Output                   static
Adapter                  none
Integrations             @astrojs/sitemap
                         astro-icon

If this issue only occurs in one browser, which browser is a problem?

No response

Describe the Bug

When using a code block in markdown a extra line is added even if I am not using one.

<pre class="astro-code github-dark" style="background-color:#24292e;color:#e1e4e8; overflow-x: auto;" tabindex="0" data-language="bash">
  <code>
    <span class="line">
      <span style="color:#B392F0">npm</span>
      <span style="color:#9ECBFF"> create</span>
      <span style="color:#9ECBFF"> astro@latest</span>
    </span>
    <span class="line"></span>
  </code>
</pre>

What's the expected result?

No extra line in the code block, I am expecting the same result as seen on github or with astro-expressive-code

<pre class="astro-code github-dark" style="background-color:#24292e;color:#e1e4e8; overflow-x: auto;" tabindex="0" data-language="bash">
  <code>
    <span class="line">
      <span style="color:#B392F0">npm</span>
      <span style="color:#9ECBFF"> create</span>
      <span style="color:#9ECBFF"> astro@latest</span>
    </span>
  </code>
</pre>

Link to Minimal Reproducible Example

https://stackblitz.com/edit/withastro-astro-t24vz7?file=src%2Fpages%2Findex.md

Participation

  • I am willing to submit a pull request for this issue.
@github-actions github-actions bot added the needs triage Issue needs to be triaged label Nov 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs triage Issue needs to be triaged
Projects
None yet
Development

No branches or pull requests

1 participant