Skip to content

docs(handbook): fix heading level for "Truthiness narrowing"#3580

Merged
RyanCavanaugh merged 1 commit into
microsoft:v2from
yezhonghu0503:fix/narrowing-truthiness-heading-level
Jun 5, 2026
Merged

docs(handbook): fix heading level for "Truthiness narrowing"#3580
RyanCavanaugh merged 1 commit into
microsoft:v2from
yezhonghu0503:fix/narrowing-truthiness-heading-level

Conversation

@yezhonghu0503
Copy link
Copy Markdown
Contributor

Summary

Fixes the heading level for "Truthiness narrowing" in the Narrowing handbook page, reported in microsoft/TypeScript#63531.

The heading was written as an H1 (# Truthiness narrowing) but every other narrowing kind on the same page — typeof type guards, Equality narrowing, in operator narrowing, instanceof narrowing, Assignments, Control flow analysis, Using type predicates, Assertion functions — is an H2. As a result the on-page Table of Contents nested all of those siblings under "Truthiness narrowing", giving readers the impression they're sub-concepts of truthiness.

Change

- # Truthiness narrowing
+ ## Truthiness narrowing

packages/documentation/copy/en/handbook-v2/Narrowing.md, one character.

Refs

AI disclosure

Used Claude to locate the file in this repo (the issue was filed on microsoft/TypeScript, not here) and to draft this description. The change itself is trivial — verified by inspecting the surrounding H2 siblings.

In the Narrowing handbook page, the "Truthiness narrowing" heading was
written as an H1 (`#`) instead of an H2 (`##`). It sits alongside the
other narrowing kinds (`typeof type guards`, `Equality narrowing`, `in
operator narrowing`, etc.) which are all H2, so it should be H2 too.

The H1 caused the on-page Table of Contents to nest every subsequent
sibling section under "Truthiness narrowing", giving readers the
impression that Equality / in / instanceof narrowing etc. are
sub-concepts of truthiness.

Refs microsoft/TypeScript#63531
@RyanCavanaugh RyanCavanaugh enabled auto-merge (squash) June 5, 2026 15:30
@RyanCavanaugh RyanCavanaugh merged commit f3cefe7 into microsoft:v2 Jun 5, 2026
8 checks passed
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

Successfully merging this pull request may close these issues.

3 participants