mirror of
https://github.com/status-im/status-react.git
synced 2025-01-24 09:49:51 +00:00
0f15c0192d
Revisions from develop: - 59ceddbaa develop origin/develop fix(wallet): fix bridge transactions (#20902) - 99ccbc338 Cover wallet send events with tests Part 2 #20411 #20533 (#20721) - 8c2d5398b Enabling WalletConnect feature flag (#20906) - 67c83b13e fix(wallet): remove edit routes button in bridging (#20874) - 11a84ba14 feat(wallet): disable complex routing (#20901) - 1f5bb579c chore(wallet): disable bridging on unsupported tokens (#20846) - 4586f8007 Add toggle in advanced settings for mobile data - 55c620e59 fix: create password for small screen (#20645) - 525609f0a Wallet Activity: transactions are not sorted by time #20808 (#20862) - 90653955a chore(settings): Disable telemetry option (#20881) - d27ab756d fix_:display group message using the new ui (#20787) - c6a1db633 ci: enable split apks & build only for arm64-v8a (#20683) - 73777e052 Ensure keycard account can send transaction after upgrading from v1 to v2 #20552 (#20845) - a6d3fc374 [#20524] fix: the missed keypairs are shown in the key pair list screen (#20888) - a671c7083 fix broken screen and navigation when syncing fails (#20887) - a45991b6d 🥅 Filter connected dapps based on testnet mode, reject proposals and requests gracefully (#20799) - 2e9fa22e4 feat: wallet router v2 (#20631) - 737d8c4d5 rename sub to fix error when requesting to join community (#20868) - 3aa7e103f Sync process is blocked on Enabled notifications screen (#20883) - c1d2d44da perf: Fix app freeze after login (#20729) - 0fed8113d e2e: updated testnet switching and added one test into smoke - 53c35cb55 fix(wallet): Linear gradient exception on invalid colors for watched account cards (#20854) - be8236554 chore(settings)_: Remove testnet toggle from legacy advanced settings (#20875) - eae8a6559 feat(wallet)_: Add beta info box in activity tab (#20873) - fe54a25a3 fix: not clearing network & web3-wallet on logout (#20886) - 15a4219ef Reject wallet-connect request by dragging the modal down (#20763) (#20836) - 2ffbdac89 WalletConnect show expired toast (#20857) - 402eb8397 fix Issue with scrolling WalletConnect transaction on Android (#20867) - ff88049a0 Fix WalletConnect header alignment on Android (#20860) - cee21241d WalletConnect no internet edge-cases (#20826) - 60ad7c8a2 chore(tests): New match-strict? cljs.test directive (#20825) - 4989c9278 fix_: Adding own address as saved addresses (#20839)
201 lines
12 KiB
Clojure
201 lines
12 KiB
Clojure
;; shadow-cljs configuration
|
|
{:source-paths ["src" "test/cljs"]
|
|
|
|
:dependencies [[reagent "1.2.0"]
|
|
[re-frame "1.4.3"]
|
|
[binaryage/oops "0.7.2"]
|
|
[com.andrewmcveigh/cljs-time "0.5.2"]
|
|
[com.taoensso/timbre "6.3.1"]
|
|
[cljs-bean "1.9.0"]
|
|
[com.cognitect/transit-cljs "0.8.280"]
|
|
[camel-snake-kebab "0.4.3"]
|
|
[metosin/malli "0.13.0"]
|
|
[funcool/promesa "11.0.678"]
|
|
|
|
;; Dev dependencies
|
|
[com.github.jpmonettas/flow-storm-inst "3.7.5"]
|
|
[refactor-nrepl "3.9.1"]
|
|
[cider/cider-nrepl "0.31.0"]
|
|
[cider/piggieback "0.4.1"]
|
|
[org.slf4j/slf4j-nop "2.0.9"]
|
|
[re-frisk-remote "1.6.0"]
|
|
[nubank/matcher-combinators "3.9.1"]
|
|
|
|
;; Use the same version specified in the Nix dependency.
|
|
[clj-kondo/clj-kondo "2024.03.13"]
|
|
|
|
;; Routing
|
|
[bidi "2.1.6"]
|
|
;; Test dependencies
|
|
[day8.re-frame/test "0.1.5"]
|
|
[com.taoensso/tufte "2.6.3"]]
|
|
|
|
;; port and middleware for repl in development
|
|
:nrepl {:port 7888
|
|
:middleware [cider.piggieback/wrap-cljs-repl
|
|
refactor-nrepl.middleware/wrap-refactor]}
|
|
|
|
;; shadow-cljs web interface
|
|
:http {:port 3449
|
|
:host "0.0.0.0"}
|
|
|
|
:cache-blockers #{legacy.status-im.utils.js-resources legacy.status-im.ui.components.icons.icons}
|
|
|
|
:builds
|
|
{:mobile
|
|
{:target :react-native
|
|
;; To match the folder created by Nix build of JSBundle.
|
|
:output-dir "result"
|
|
:init-fn status-im.core/init
|
|
;; When false, the Shadow-CLJS watcher won't automatically refresh
|
|
;; the target files (a.k.a hot reload). When false, you can manually
|
|
;; reload by calling `shadow.cljs.devtools.api/watch-compile-all!`.
|
|
:devtools {:autobuild #shadow/env ["SHADOW_AUTOBUILD_ENABLED" :default true :as :bool]}
|
|
:dev {:devtools {:before-load-async status-im.setup.hot-reload/before-reload
|
|
:after-load-async status-im.setup.hot-reload/reload
|
|
:build-notify status-im.setup.hot-reload/build-notify
|
|
:preloads [;; The official recommendation is to
|
|
;; load the debugger preload first.
|
|
flow-storm.api
|
|
re-frisk-remote.preload
|
|
status-im.setup.schema-preload
|
|
;; In order to use component test helpers in the REPL we
|
|
;; need to preload namespaces that are not normally required
|
|
;; by production code, such as
|
|
;; @testing-library/react-native.
|
|
test-helpers.component]}
|
|
:closure-defines
|
|
{status-im.config/POKT_TOKEN #shadow/env "POKT_TOKEN"
|
|
status-im.config/INFURA_TOKEN #shadow/env "INFURA_TOKEN"
|
|
status-im.config/MIXPANEL_APP_ID #shadow/env "MIXPANEL_APP_ID"
|
|
status-im.config/MIXPANEL_TOKEN #shadow/env "MIXPANEL_TOKEN"
|
|
status-im.config/OPENSEA_API_KEY #shadow/env "OPENSEA_API_KEY"
|
|
status-im.config/RARIBLE_MAINNET_API_KEY #shadow/env "RARIBLE_MAINNET_API_KEY"
|
|
status-im.config/RARIBLE_TESTNET_API_KEY #shadow/env "RARIBLE_TESTNET_API_KEY"
|
|
status-im.config/ALCHEMY_ETHEREUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
|
status-im.config/ALCHEMY_ETHEREUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ETHEREUM_GOERLI_TOKEN"
|
|
status-im.config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
|
status-im.config/ALCHEMY_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
|
status-im.config/ALCHEMY_ARBITRUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ARBITRUM_GOERLI_TOKEN"
|
|
status-im.config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
|
status-im.config/ALCHEMY_OPTIMISM_MAINNET_TOKEN #shadow/env "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
|
status-im.config/ALCHEMY_OPTIMISM_GOERLI_TOKEN #shadow/env "ALCHEMY_OPTIMISM_GOERLI_TOKEN"
|
|
status-im.config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"}
|
|
:compiler-options {:output-feature-set :es5
|
|
;; We disable `:fn-deprecated` warnings because we
|
|
;; are managing deprecation via clj-kondo and we
|
|
;; don't want the terminal output to be littered
|
|
;; with warnings on every code reload.
|
|
:warnings {:fn-deprecated false}
|
|
:closure-defines {re-frame.trace/trace-enabled? true}
|
|
:source-map false
|
|
;; This seems to be necessary while using the REPL,
|
|
;; otherwise sometimes you'll get weird errors when
|
|
;; instrumenting functions.
|
|
:static-fns false
|
|
:infer-externs true}
|
|
;; if you want to use a real device, set your local ip
|
|
;; in the SHADOW_HOST env variable to make sure that
|
|
;; it will use the right interface
|
|
:local-ip #shadow/env "SHADOW_HOST"}
|
|
:chunks {:fleets legacy.status-im.fleet.default-fleet/default-fleets}
|
|
:release
|
|
{:closure-defines
|
|
{status-im.config/POKT_TOKEN #shadow/env "POKT_TOKEN"
|
|
status-im.config/INFURA_TOKEN #shadow/env "INFURA_TOKEN"
|
|
status-im.config/OPENSEA_API_KEY #shadow/env "OPENSEA_API_KEY"
|
|
status-im.config/MIXPANEL_APP_ID #shadow/env "MIXPANEL_APP_ID"
|
|
status-im.config/MIXPANEL_TOKEN #shadow/env "MIXPANEL_TOKEN"
|
|
status-im.config/RARIBLE_MAINNET_API_KEY #shadow/env "RARIBLE_MAINNET_API_KEY"
|
|
status-im.config/RARIBLE_TESTNET_API_KEY #shadow/env "RARIBLE_TESTNET_API_KEY"
|
|
status-im.config/ALCHEMY_ETHEREUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
|
status-im.config/ALCHEMY_ETHEREUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ETHEREUM_GOERLI_TOKEN"
|
|
status-im.config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
|
status-im.config/ALCHEMY_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
|
status-im.config/ALCHEMY_ARBITRUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ARBITRUM_GOERLI_TOKEN"
|
|
status-im.config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
|
status-im.config/ALCHEMY_OPTIMISM_MAINNET_TOKEN #shadow/env "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
|
status-im.config/ALCHEMY_OPTIMISM_GOERLI_TOKEN #shadow/env "ALCHEMY_OPTIMISM_GOERLI_TOKEN"
|
|
status-im.config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"}
|
|
:compiler-options {:output-feature-set :es6
|
|
;;disable for android build as there
|
|
;;is an intermittent warning with deftype
|
|
:warnings-as-errors false
|
|
:infer-externs :auto
|
|
:static-fns true
|
|
:fn-invoke-direct true
|
|
:optimizations :advanced
|
|
:js-options {:js-provider :closure}}}}
|
|
;; the tests are ran with node, react-native dependencies are mocked
|
|
;; by using node --require override.js, which uses the node-library
|
|
;; produced by the target :mocks below and redefines node require
|
|
;; function to use the mocks instead of the rn libraries
|
|
:test
|
|
{:output-to #shadow/env "SHADOW_OUTPUT_TO"
|
|
:output-dir "target/test"
|
|
:optimizations :simple
|
|
:target :node-test
|
|
:dev {:devtools {:preloads [status-im.setup.schema-preload
|
|
status-im.setup.test-preload]}}
|
|
;; Uncomment line below to `make test-watch` a specific file
|
|
:ns-regexp #shadow/env "SHADOW_NS_REGEXP"
|
|
:main legacy.status-im.test-runner/main
|
|
;; set :ui-driven to true to let shadow-cljs inject node-repl
|
|
:ui-driven true
|
|
:closure-defines
|
|
{schema.core/throw-on-error? true
|
|
status-im.config/POKT_TOKEN #shadow/env "POKT_TOKEN"
|
|
status-im.config/INFURA_TOKEN #shadow/env "INFURA_TOKEN"
|
|
status-im.config/OPENSEA_API_KEY #shadow/env "OPENSEA_API_KEY"
|
|
status-im.config/MIXPANEL_APP_ID #shadow/env "MIXPANEL_APP_ID"
|
|
status-im.config/MIXPANEL_TOKEN #shadow/env "MIXPANEL_TOKEN"
|
|
status-im.config/RARIBLE_MAINNET_API_KEY #shadow/env "RARIBLE_MAINNET_API_KEY"
|
|
status-im.config/RARIBLE_TESTNET_API_KEY #shadow/env "RARIBLE_TESTNET_API_KEY"
|
|
status-im.config/ALCHEMY_ETHEREUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ETHEREUM_MAINNET_TOKEN"
|
|
status-im.config/ALCHEMY_ETHEREUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ETHEREUM_GOERLI_TOKEN"
|
|
status-im.config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ETHEREUM_SEPOLIA_TOKEN"
|
|
status-im.config/ALCHEMY_ARBITRUM_MAINNET_TOKEN #shadow/env "ALCHEMY_ARBITRUM_MAINNET_TOKEN"
|
|
status-im.config/ALCHEMY_ARBITRUM_GOERLI_TOKEN #shadow/env "ALCHEMY_ARBITRUM_GOERLI_TOKEN"
|
|
status-im.config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_ARBITRUM_SEPOLIA_TOKEN"
|
|
status-im.config/ALCHEMY_OPTIMISM_MAINNET_TOKEN #shadow/env "ALCHEMY_OPTIMISM_MAINNET_TOKEN"
|
|
status-im.config/ALCHEMY_OPTIMISM_GOERLI_TOKEN #shadow/env "ALCHEMY_OPTIMISM_GOERLI_TOKEN"
|
|
status-im.config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN #shadow/env "ALCHEMY_OPTIMISM_SEPOLIA_TOKEN"
|
|
status-im.config/WALLET_CONNECT_PROJECT_ID #shadow/env "WALLET_CONNECT_PROJECT_ID"}
|
|
:compiler-options
|
|
{;; needed because we override require and it
|
|
;; messes with source-map which reports callstack
|
|
;; exceeded exceptions instead of real issues
|
|
:source-map false
|
|
;; needed because we use deref in tests
|
|
:static-fns false
|
|
:optimizations :simple
|
|
:warnings {:fn-deprecated false}
|
|
:infer-externs true}}
|
|
|
|
;; mock.js-dependencies is mocking the react-native libraries
|
|
;; we build it as a node library so that it can be required by
|
|
;; override.js
|
|
:mocks
|
|
{:target :node-library
|
|
:exports {:mocks mocks.js-dependencies/mock}
|
|
:output-to "target/mocks/mocks.js"
|
|
:output-dir "target/mocks"
|
|
:compiler-options {:optimizations :simple
|
|
:source-map false}}
|
|
:component-test {:target :npm-module
|
|
:entries [;; We need to tell shadow-cljs to compile
|
|
;; the preloads namespaces because they
|
|
;; will be used directly by Jest in the
|
|
;; option setupFilesAfterEnv.
|
|
test-helpers.component-tests-preload
|
|
status-im.setup.schema-preload
|
|
quo.core-spec
|
|
status-im.core-spec]
|
|
:ns-regexp "component-spec$"
|
|
:output-dir "component-spec"
|
|
:closure-defines {schema.core/throw-on-error? true}
|
|
:compiler-options {:warnings-as-errors false
|
|
:warnings {:fn-deprecated false}
|
|
:static-fns false
|
|
:infer-externs true}}}}
|