TanStack / TanStack/virtual

docs: Subsequent headers are put on the same line

Open
#950 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
7.1k
Forks
466
Avg merge
2d 31m
Merged PRs (30d)
13

Description

Describe the bug

If two headings are immediately following eachother, the second heading is rendered on the same line as the first.

This is visible on the Virtualizer page, where there is an h2 followed by an h3

Image

This seems to be a CSS issue, as these headers are wrapped in <a> tags, which might be being rendered inline. This might be an issue with the TanStack docs generation instead of virtual itself, as the markdown for this page looks pretty normal: https://github.com/TanStack/virtual/blob/main/docs/api/virtualizer.md

Observed on Chromium

Your minimal, reproducible example

https://tanstack.com/virtual/latest/docs/api/virtualizer

Steps to reproduce
  1. Go to https://tanstack.com/virtual/latest/docs/api/virtualizer
  2. Look for the #required and #optional headers
  3. ???
  4. Profit
Expected behavior

Headers are on separate lines, even if immediately preceded by another header.

How often does this bug happen?

Every time

Screenshots or Videos

No response

Platform

Chromium on MacOS

tanstack-virtual version

v3.13.2

TypeScript version

No response

Additional context

No response

Terms & Code of Conduct
  • I agree to follow this project's Code of Conduct
  • I understand that if my bug cannot be reliable reproduced in a debuggable environment, it will probably not be fixed and this issue may even be closed.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the linked Virtualizer documentation page and its source markdown to compare the generated heading markup, especially the #required and #optional headings. Inspect the CSS applied to the heading anchor tags and identify why adjacent headings render inline; done means consecutive headings appear on separate lines in Chromium.

Written by the indexing model from the issue text.

Assessment

Tech stack
css
Domain
documentation
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.