mark-fe-fwk 1.0.1 → 1.0.2

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.
@@ -192,6 +192,14 @@ class Dispatcher {
192
192
  this.#afterHandlers.splice(idx, 1);
193
193
  }
194
194
  }
195
+ dispatch(commandName, payload) {
196
+ if (this.#subs.has(commandName)) {
197
+ this.#subs.get(commandName).forEach((handler) => handler(payload));
198
+ } else {
199
+ console.warn(`No handlers for command: ${commandName}`);
200
+ }
201
+ this.#afterHandlers.forEach((handler) => handler());
202
+ }
195
203
  }
196
204
 
197
205
  function createApp({state, view, reducers = {} }) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mark-fe-fwk",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "author": "Mark C",
5
5
  "main": "dist/mark-fe-fwk.js",
6
6
  "files": [