Skip to content

Instantly share code, notes, and snippets.

@madvas
Created October 3, 2016 17:26
Show Gist options
  • Save madvas/b5c8b35c1d586db4ae791c3812d61611 to your computer and use it in GitHub Desktop.
Save madvas/b5c8b35c1d586db4ae791c3812d61611 to your computer and use it in GitHub Desktop.
:contract/settings-loaded
(reg-event-db
:contract/settings-loaded
interceptors
(fn [db [[max-name-length max-tweet-length]]]
(assoc db :settings {:max-name-length (.toNumber max-name-length)
:max-tweet-length (.toNumber max-tweet-length)})))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment