packages/odo-module/src/module.js
function register(Module, selector) {
  const _selector = getSelector(Module, selector);

  validate(Module, _selector);

  const methods = OdoModuleMethods(Module, _selector);

  // Apply OdoModule static methods.
  Object.keys(methods).forEach((method) => {
    Module[method] = methods[method];
  });

  // Apply the OdoModule static property.
  Module.Instances = new Map();

  // Internally register the module.
  store.set(_selector, Module);

  return Module;
}
function register(Module, selector) {
  const _selector = getSelector(Module, selector);

  validate(Module, _selector);

  const methods = OdoModuleMethods(Module, _selector);

  // Apply OdoModule static methods.
  Object.keys(methods).forEach((method) => {
    Module[method] = methods[method];
  });

  // Apply the OdoModule static property.
  Module.Instances = new Map();

  // Internally register the module.
  store.set(_selector, Module);

  return Module;
}
function register ( Module , selector ) { const _selector = getSelector ( Module , selector ) ; validate ( Module , _selector ) ; const methods = OdoModuleMethods ( Module , _selector ) ; // Apply OdoModule static methods. Object . keys ( methods ) . forEach ( ( method ) => { Module [ method ] = methods [ method ] ; } ) ; // Apply the OdoModule static property. Module . Instances = new Map ( ) ; // Internally register the module. store . set ( _selector , Module ) ; return Module ; }
Adds static methods and internally registers the module.
@param {Object} Module
@param {string} [selector]
@return {Object} The module.
Adds static methods and internally registers the module .