@metalsadman Looks like just what I need, thank you!
Posts made by taylorg
RE: Adding API URL to process.env for three different situations
Adding API URL to process.env for three different situations
I’m new to Quasar, and I’m trying to add our API URLs to process.env through quasar.conf.js. I have been successfully able to configure the API for development and production environments by following this guide: https://quasar.dev/quasar-cli/cli-documentation/handling-process-env
The issue is that I need to make the Quasar app mimic our backend in terms of the possible environments. Our app can run in three separate environments, local on the developer’s machine, on our dev server, and on our production server. Each one of these situations requires a different API URL. On the local machine, Quasar is run using ‘quasar dev’, but on both the dev and production servers, we run a ‘quasar build’ before deploying.
Is there an easy way to set this up? I’m stuck on how I can differentiate between the dev and production servers when in quasar.conf.js, and thus set the correct value for the API URL. Any help would be much appreciated.