← All components Editors
EditorOutline
Notion/Bear sidebar TOC. Walks markdown for ATX headings; deterministic slugs; active-heading highlight.
Inspired by Notion outline sidebar, Bear table of contents.
Preview
What it looks like.
Usage
Drop it into your app.
import { EditorOutline } from '@locara/components'
<EditorOutline
source={markdown}
activeSlug={currentHeading}
maxDepth={3}
onJump={({ offset, slug }) => scrollEditorToOffset(offset)}
title="On this page"
/>
Or copy the source into your repo:
locara add editor-outline