label - describes the rule
trigger - when these topic values are all defined and they change, run the rule
given - give this information to the rule
when - returns true if we should run then, false if we should not run then
then - run this closure to return new facts or other side effects
defaultValues - if the fact is not defined, set this fact before running the rule
Still need to break out assistants into little rules instead of having big hunks of code
Refactor rules to take params:
label - describes the rule trigger - when these topic values are all defined and they change, run the rule given - give this information to the rule when - returns true if we should run
then
, false if we should not runthen
then - run this closure to return new facts or other side effects defaultValues - if the fact is not defined, set this fact before running the ruleStill need to break out assistants into little rules instead of having big hunks of code