-
Notifications
You must be signed in to change notification settings - Fork 10
cursor _
jiyinyiyong edited this page Mar 21, 2020
·
2 revisions
Removed in
0.12.x
.
Suppose you want to add a sub cursor called k
, which is a keyword, number or string:
(cursor-> k comp-demo states p1 p2)
(assoc (comp-demo (get states k) p1 p2) :cursor k)
Also you need to select k
in states
, which is a tree.
Make sure the tree created with cursor->
function corresponds to the tree of state. An variable called cursor
will be injected into render function as a parameter for dispatching.