../

Use the ParcelJS proxy for your api

To better simulate the production environment during web app development, you can specify proxy paths in a .proxyrc, .proxyrc.json, or .proxyrc.js file. This allows certain requests to be redirected to your real API server or a local testing server, ensuring your development environment closely mirrors production.

For example:

// .proxyrc
{
  "/api": {
    "target": "http://0.0.0.0:8000/"
  }
}

See https://parceljs.org/features/development/#api-proxy

Thats it 😀

until-we-meet-again.png