This article guides you through uploading source maps for your front-end scripts in Bugpilot.
Source maps help make error messages, and stack traces more readable. When you upload source maps to Bugpilot, you will benefit from easier-to-read stack traces when front-end or network errors occur right in your Bugpilot reports.
Grab a Bugpilot CLI executable from here: Download Bugpilot CLI. You can add the CLI to your project or download it every time a build runs.
curl -o bugpilot-cli <https://cli-downloads.bugpilot.io/bugpilot_linux_amd64>
Get a Source Map Upload Secret from your Bugpilot Dashboard, under Integrations > Source Maps.
You will need to update your CI/CD pipeline to execute one additional command when deploying a new version, similar to what you probably already did with Sentry.
Add the following command after you build a frontend build project. This command will need to execute every time a new version of your app is deployed:
./bugpilot -workspaceId <BUGPILOT-WORKSPACE-ID> -auth <BUGPILOT-FILES-UPLOAD-SECRET> upload-sourcemaps
This command uploads all the .js.map files it can find in the current folder and all its subfolders to Bugpilot.