← all repositories

stackblitz-labs/use-stick-to-bottom

A zero-dependency React hook that auto-scrolls chat interfaces to the latest message with smooth animation.

740 stars TypeScript Other AI
use-stick-to-bottom
Velocity · 7d
+1.2
★ / day
Trend
steady
star history

This is a lightweight React hook and component that automatically sticks chat interfaces to the bottom as new messages arrive. It uses ResizeObserver to detect content changes and correctly handles scroll anchoring to prevent visual jumps. The hook is explicitly marketed for AI chat applications and is noted as powering StackBlitz bolt.new, an AI-powered coding assistant.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.