This page includes reference documentation for the global config singleton available in the Mapbox Search JS Web framework.
Global configuration singleton object storing settings shared across Search JS Web components.
| Name | Description |
|---|---|
| accessToken string | A Mapbox access token used if one is not passed in explicitly to web components. |
| feedbackEnabled boolean | If true, Address Autofill address or marker location corrections will be submitted to the Mapbox Contribute API to help improve our data accuracy. Defaults to true. |
config.accessToken = 'pk.abc.123';
...
// Don't need to explicitly pass in token to some components
autofill({});
confirmAddress(form);