Testing
Test on Desktop
- Open the Simulator/Preview
- Click the browser pop-out button

Test on Mobile
To test your project on mobile devices, especially for AR experiences that require camera access, you'll need to serve your development server over HTTPS. We recommend using ngrok to create a secure tunnel to your local server.
- Go to ngrok.com and create an account. Once signed in, follow the steps on the dashboard to install ngrok.
- Update (or verify) your project configuration. In the
configfolder, openwebpack.config.jsand look for thedevServerobject. Add (or verify) ngrok as anallowedHost:
devServer: {
// ... existing config
allowedHosts: ['.ngrok-free.dev']
}
- Relaunch the desktop app or exit/reopen the project to refresh the build after updating the webpack configuration
- Open the Simulator/Preview and click the browser pop-out button

- From the new browser window, copy the port number appended to the end of the localhost URL

- Open a terminal window and run the following command, replacing [port] with the port obtained from the simulator browser pop-out
ngrok http [port]
In the output you should see an ngrok URL that uses HTTPS and forwards to your local development server. You can paste this into your browser window and test your project on a mobile device.
