From 966f6de31af3cb7bb79b1b457e46f721068c5a5a Mon Sep 17 00:00:00 2001 From: Andrea Maria Piana Date: Mon, 5 Oct 2020 12:00:37 +0200 Subject: [PATCH] Fix infura token Setting a top-level closure-defines does not have any effect, it needs to be for some reason inside each environment. Signed-off-by: Andrea Maria Piana --- shadow-cljs.edn | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/shadow-cljs.edn b/shadow-cljs.edn index 7b4e8124b3..27c3f9d187 100644 --- a/shadow-cljs.edn +++ b/shadow-cljs.edn @@ -38,7 +38,6 @@ {:target :react-native :output-dir "app" :init-fn status-im.core/init - :closure-defines {"status-im.utils.config/INFURA_TOKEN" #shadow/env "INFURA_TOKEN"} :dev {:devtools {:after-load status-im.reloader/reload :build-notify status-im.reloader/build-notify :preloads [re-frisk-remote.preload]} @@ -53,7 +52,8 @@ :local-ip #shadow/env "SHADOW_HOST"} :chunks {:fleets status-im.default-fleet/default-fleets :chats status-im.chat.default-chats/default-chats} - :release {:compiler-options {:output-feature-set :es6 + :release {:closure-defines {status-im.utils.config/INFURA_TOKEN #shadow/env "INFURA_TOKEN"} + :compiler-options {:output-feature-set :es6 ;;disable for android build as there ;;is an intermittent warning with deftype :warnings-as-errors false @@ -70,8 +70,8 @@ {:output-to "target/test/test.js" :output-dir "target/test" :optimizations :simple - :closure-defines {status-im.utils.config/INFURA_TOKEN #shadow/env "INFURA_TOKEN"} :target :node-test + :closure-defines {status-im.utils.config/INFURA_TOKEN #shadow/env "INFURA_TOKEN"} :compiler-options {;; needed because we override require and it ;; messes with source-map which reports callstack ;; exceeded exceptions instead of real issues