/**
 * Skipped minification because the original files appears to be already minified.
 * Original file: /npm/beedle@0.8.1/dist/beedle.umd.js
 *
 * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
 */
!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?module.exports=n():"function"==typeof define&&define.amd?define(n):t.beedle=n()}(this,function(){"use strict";class t{constructor(t){const n=this;n.actions={},n.mutations={},n.state={},n.status="resting",n.callbacks=[],t.hasOwnProperty("actions")&&(n.actions=t.actions),t.hasOwnProperty("mutations")&&(n.mutations=t.mutations),n.state=new Proxy(t.initialState||{},{set(t,o,s){return t[o]=s,n.processCallbacks(n.state),n.status="resting",!0}})}dispatch(t,n){const o=this;return"function"!=typeof o.actions[t]?(console.error(`Action "${t}" doesn't exist.`),!1):(o.status="action",o.actions[t](o,n))}commit(t,n){const o=this;if("function"!=typeof o.mutations[t])return console.error(`Mutation "${t}" doesn't exist`),!1;o.status="mutation";let s=o.mutations[t](o.state,n);return o.state=s,!0}processCallbacks(t){const n=this;return!!n.callbacks.length&&(n.callbacks.forEach(n=>n(t)),!0)}subscribe(t){const n=this;return"function"!=typeof t?(console.error("You can only subscribe to Store changes with a valid function"),!1):(n.callbacks.push(t),!0)}}return t});
