Uses Vite to bundle and serve files.
To run this example, you need a Mapbox access token. You can either set an environment variable:
export MapboxAccessToken=<mapbox_access_token>
Or set MAPBOX_TOKEN
directly in app.jsx
.
Other options can be found at using with Mapbox GL.
To install dependencies:
npm install
# or
yarn
Commands:
npm start
is the development target, to serve the app and hot reload.npm run build
is the production target, to create the final bundle and write to disk.