It would be great to have an action that could be a used to run JavaScript after all forms events were complete. Personally, I would use it to close popups and windows when the AddSuccess and EditSuccess templates are not needed, but there may be a lot of other uses too. Something like...
<ScriptAction RunIf='[[MyToggle]] = True' Script='MyScript()' >