Module: App

App

Source:

Members

config

Source:
Example
config = {
 type: "exams",
 interval: 10,
 host: "school.elasticnode.ru",
 container: "body",
 title: "My title",
}

Methods

<static> destroy() → {string}

Widget annihilation
Source:
Returns:
Message
Type
string

<static> getNode() → {object|null}

Returns view.$el if exists or null
Source:
Returns:
$container or null
Type
object | null

<static> getStatus()

Returns current widget status
Source:

<static> setConfig(config)

Sets a new widget config
Parameters:
Name Type Description
config Object Config object
Source:

setMode(arguments) → {boolean}

Asynchronous widget mode set
Parameters:
Name Type Description
arguments * Any arguments
Source:
See:
Returns:
True if .switchModeDelayed() method defined
Type
boolean

<inner> applyConfig(config)

Applies new config to current widget
Parameters:
Name Type Argument Description
config Object <optional>
Config object
Source:

<inner> flushView(view)

Assigned view destructor
Parameters:
Name Type Description
view Object Backbone.View instance
Source:

<inner> Loader()

Returns or creates a new one renderer instance
Source:

<inner> loadRenderer(path)

Loads the view.render instance as renderer
Parameters:
Name Type Description
path String Module related path
Source:

<inner> renderer()

View render function
Source:

<inner> validateConfig(_config) → {Object}

Validates config object and handles its errors
Parameters:
Name Type Argument Description
_config Object <optional>
Config object. If undefined actual config will be used
Source:
Returns:
Correct config or error object
Type
Object