API Docs for: 0.0.1
Show:

window.define Class

Module: window

define a new module so that you don't care how to create an instance of module. and the method was exposed to global scope

Constructor

window.define

(
  • id
  • [req]
  • factory
)
Module static

Parameters:

  • id String

    the module name for the instance, it should be unique and the namspace is expected like 'mywork/module1'

  • [req] Array optional

    the required modules for this module

  • factory Function

    the factory function for the module

Returns:

Module: an instance of Module

Item Index