core.orb.jsdoc

/**
 * @module orbx-core
 * @description Module that provides basic functionality to create `orbx` childs and clean copies
 */

/**
 * @function
 * @name orb
 * @description Create new child that add current object to prototype chain + newly passed object. <br> - New object maight be any JS object (function, array, object, string, number).<br> - Function input is binded to `exec` method.<br> - Name property is assigned to `name` of new object.<br> - New object is set as child to its proto. To prevent that pass second argument = false.
 * @example
 * const test = core.spawn();
 * function Component1(){console.log(this.vluae)}
 * Component1.value = 1;
 * const orb1 = test.orb(Component1);
 * orb1.run() // 1;
 * @param {(Function | Array | Object | String | Number)} input
 * @param {Boolean} record flag if input should be add to prototype child or not
 * @return {Void}
 * @access public
 */

/**
 * @function
 * @name exec
 * @description function execute function binded to orb while creating new orb
 * @return {Void}
 * @access public
 */

/**
 * @function
 * @name spawn
 * @description Create clean version of orbx object
 * @example
 *     const test = core.spawn();
 * @access public
 */