Loading Bar

Shows a line along the window's top while a slow page loads.

View as Markdown

Installation

Usage

Render one at the root of the app and set loading while a page loads. It shows only once a load outlasts 150ms, so a fast one never flashes, then creeps toward its end until loading turns false.

Router

Pass the router's loading state to loading. With TanStack Router, read it with useRouterState in the root route.

API Reference

LoadingBar

Takes every prop of Base UI Progress's root except value, plus:

It renders a progressbar with no value. Name it with aria-label.