Skip to content

Instantly share code, notes, and snippets.

@madvas
Created October 3, 2016 16:25
Show Gist options
  • Save madvas/df77b847cc6d71995f2685064a88b83d to your computer and use it in GitHub Desktop.
Save madvas/df77b847cc6d71995f2685064a88b83d to your computer and use it in GitHub Desktop.
initialize
(reg-event-fx
:initialize
(fn [_ _]
(merge
{:db db/default-db
:dispatch [:contract/fetch-compiled-code [:contract/compiled-code-loaded]]}
(when (:provides-web3? db/default-db)
{:web3-fx.blockchain/fns
{:web3 (:web3 db/default-db)
:fns [[web3-eth/accounts :blockchain/my-addresses-loaded :log-error]]}}))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment