React Component for Address Lookup
Address Lookup now ships a React integration. The @addresszen/react package gives you a drop-in <AddressLookup> component, so adding address autocomplete to a React app no longer means hand-wiring effects and refs. Available now on npm as @addresszen/react 2.0.0.
Details
- Drop-in component: Render
<AddressLookup>and you are done. NouseEffect, nouseRef, no manual setup or teardown - Use your own input: Let the component render its own field, or wrap an input you already have so it fits cleanly with design systems such as shadcn/ui, MUI and Mantine
- Every callback as a prop: Hook into the full widget lifecycle through props like
onAddressRetrieved. Inline callbacks always see your latest state, with nouseCallbackneeded - Sensible defaults: Defaults to US addresses, and the stylesheet auto-injects or can be imported yourself for server-side rendering
- Works everywhere React does: Next.js App Router (
"use client") and Pages Router, Remix and Astro, on React 18 and 19
Get started
Install @addresszen/react from npm:
npm install @addresszen/react
See the React integration guide for setup and examples, or the Address Lookup docs for the wider widget.
Already using Address Lookup for React 1.x? Version 2.0.0 is a ground-up rewrite with a new API. Follow the guide above when upgrading.