From e68709f9f1ca9d22aecbf783b972c3a838ee5a3d Mon Sep 17 00:00:00 2001 From: Buck Doyle Date: Tue, 2 Jul 2019 08:58:43 -0500 Subject: [PATCH] Add Mirage-toggling via environment variable (#5899) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit I’m finding myself having to revert my change to this variable when I switch branches, so this would let me affect the variable without code changes. --- ui/config/environment.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ui/config/environment.js b/ui/config/environment.js index 626a14295..56f9179f0 100644 --- a/ui/config/environment.js +++ b/ui/config/environment.js @@ -1,6 +1,10 @@ /* eslint-env node */ -const USE_MIRAGE = true; +let USE_MIRAGE = true; + +if (process.env.USE_MIRAGE) { + USE_MIRAGE = process.env.USE_MIRAGE == 'true'; +} module.exports = function(environment) { var ENV = {