-
Notifications
You must be signed in to change notification settings - Fork 0
Description
Writting in progress
We have been playing around with rules for quite some time now, but debugging them might be tricky. Would that be possible to have a clear way to debug them ? Wheter, replaying them, or getting the parts logged at some point (giving a clear state of the rules at each time ?)
Moreover, would that be possible to have precompile-errors shown if there is ? (this might require another ticket).
Solution Proposal :
Replay them like a movie. That would be the must, getting to play with states of the rules and getting to run forward and backward with a clear API. Even though it would require to run the rules from the beggining at each time. Like :
var rule = applyRules({debug:true});
rule.run(); //getting the result
rule.playForward(); //getting next step
rule.playBackward(); //getting previous step
rule.getStepsNumber(); //getting all steps number
rule.runToStep(4); //getting rule run until step 4
//and some other that might be relevantWith that API we could make a good UI debugger and facilitate our rule implementation process.
Not touching the current state without the debug option:
var rule = applyRules()