I've got two stores, one is a dev store and the other is out production store. I develop our theme locally and deploy to the dev store periodically. When we are ready to launch we then apply the theme to the production store.
We make requests to different end points depending on which environment the store is running in (local, dev store, prod store) and want to be able to pass these in as environment variables, or at least detect in liquid which environment we are running in.
I can't quite work out who to do it. Passing the `--environment` flag to `shopify theme dev` doesn't seem to do anything, and even if it did I can't figure out how to access the shopify.theme.toml variables in liquid anyway.
The closest I can get is to check the request.canonical_url or request.host value but that doesn't work for local dev.