UNPKG

mutants-appfx

Version:

appfx module

19 lines (14 loc) 519 B
const UILoading = { registerImpl:(loadingImpl)=>{ if(!!loadingImpl && typeof loadingImpl.show === 'function'&& typeof loadingImpl.destroy === 'function'){ UILoading.loadingImpl = loadingImpl; } }, show:(message)=>{ UILoading.loadingImpl && UILoading.loadingImpl.show && UILoading.loadingImpl.show(message); }, destroy:()=>{ UILoading.loadingImpl && UILoading.loadingImpl.destroy && UILoading.loadingImpl.destroy(); } } export default UILoading;