UNPKG

ziko

Version:

A versatile JavaScript library offering a rich set of Hyperscript Based UI components, advanced mathematical utilities, interactivity ,animations, client side routing and more ...

8 lines 305 B
export const renderer = async (target, component, props, wrapper) =>{ if(!component) return; let mounted = await component(props); if(wrapper) mounted = wrapper(mounted); mounted instanceof Array ? mounted.forEach(el => el.mount(target)) : mounted.mount(target); }