Interface RequireDefine

Index

Call signatures

Call signatures

(config: { [key: string]: any; })

Define Simple Name/Value Pairs

Parameters

  • config: { [key: string]: any; }

    Dictionary of Named/Value pairs for the config.

(func: () => any)

Define function.

Parameters

  • func: () => any

(deps: Array<string>, ready: Function)

Define function with dependencies.

Parameters

  • deps: Array<string>

    List of dependencies module IDs.

  • ready: Function

    Callback function when the dependencies are loaded. callback param deps module dependencies callback return module definition

(ready: (require: Require, exports: { [key: string]: any; }, module: RequireModule) => any)

Define module with simplified CommonJS wrapper.

Parameters

  • ready: (require: Require, exports: { [key: string]: any; }, module: RequireModule) => any
    callback require requirejs instance
    callback exports exports object
    callback module module
    callback return module definition
    

(name: string, deps: Array<string>, ready: Function)

Define a module with a name and dependencies.

Parameters

  • name: string

    The name of the module.

  • deps: Array<string>

    List of dependencies module IDs.

  • ready: Function

    Callback function when the dependencies are loaded. callback deps module dependencies callback return module definition

(name: string, ready: Function)

Define a module with a name.

Parameters

  • name: string

    The name of the module.

  • ready: Function

    Callback function when the dependencies are loaded. callback return module definition