Search Box
Public beta for Mapbox Search JS
Mapbox Search JS is in public beta. During the public beta phase, frameworks may be subject to potential changes as they stabilize.
SearchBox
<SearchBox>
is a React component that provides an interactive search box,
powered by the Mapbox Search Box API.
To use this element, you must have a Mapbox access token.
Internally, this wraps the <mapbox-search-box>
element.
Parameters
props
(SearchBoxProps)
Example
export function Component() {const [value, setValue] = React.useState('');return (<form><SearchBox accessToken={<your access token here>} /></form>);}