jssm 5.59.0 → 5.59.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -101,6 +101,7 @@ declare class Machine<mDT> {
101
101
  set_hook(HookDesc: HookDescription): void;
102
102
  hook(from: string, to: string, handler: HookHandler): Machine<mDT>;
103
103
  hook_action(from: string, to: string, action: string, handler: HookHandler): Machine<mDT>;
104
+ hook_global_action(action: string, handler: HookHandler): Machine<mDT>;
104
105
  hook_any_action(handler: HookHandler): Machine<mDT>;
105
106
  hook_any_transition(handler: HookHandler): Machine<mDT>;
106
107
  hook_entry(to: string, handler: HookHandler): Machine<mDT>;
package/dist/es6/jssm.js CHANGED
@@ -755,6 +755,11 @@ class Machine {
755
755
  this.set_hook({ kind: 'named', from, to, action, handler });
756
756
  return this;
757
757
  }
758
+ hook_global_action(action, handler) {
759
+ // TODO: should this throw if setting the hook fails, or ignore it and continue?
760
+ this.set_hook({ kind: 'global action', action, handler });
761
+ return this;
762
+ }
758
763
  hook_any_action(handler) {
759
764
  // TODO: should this throw if setting the hook fails, or ignore it and continue?
760
765
  this.set_hook({ kind: 'any action', handler });
@@ -1,2 +1,2 @@
1
- const version = "5.59.0";
1
+ const version = "5.59.1";
2
2
  export { version };