-
Notifications
You must be signed in to change notification settings - Fork 3
dispatch
Matheus Marsiglio edited this page Aug 19, 2018
·
1 revision
dispatch
is the only to save something in the store. It is provided to you through the createStore
function and is a curried function. It structure requires first execute dispatch passing the contract name, for example, if you want to dispatch something to a contract named as user
:
const { dispatch } = createStore(contracts);
dispatch('user')(data);
It first identify delegates verifications to the lawyer functionality, which gets the contract name and its contract to serialize and do validations between the original contract written for user
and the data
you provided.