The Action Context uses a mechanism called addons to provide functionality that lives both
on the server and client. Each addon provides additional functions through a namespacing
object that is appended to the ActionContext object. The ActionContext object
is available in each controller function, but controllers need to
require addons before accessing addon methods.
See the ActionContext Class
for the addon classes.

Prior to version 0.5.0, Mojito attached addons to the ActionContext object for
every HTTP request and mojit instance. As a result, you were able to use
any of the Action Context addons by default.

In Mojito versions 0.5.0 and later, you need to explicitly require an addon before you
can use it. You require an addon by including an associated string in the
requires array of your controller. For example, in the controller below,
the Params addon is required by adding the string 'mojito-params-addon'
to the requires array.

YUI.add('Foo',function(Y,NAME){Y.namespace('mojito.controllers')[NAME]={index:function(ac){varall_params=ac.params.all();}};// Require the addon by adding the param name to the requires array},'0.0.1',{requires:['mojito','mojito-params-addon']});

The list below shows what strings are used to require addons.

Assets addon - requires['mojito-assets-addon']

Composite addon - requires['mojito-composite-addon']

Config addon - requires['mojito-config-addon']

Cookies addon - requires['mojito-cookie-addon']

Http addon - requires['mojito-http-addon']

Intl addon - requires['mojito-intl-addon']

Params addon - requires['mojito-params-addon']

Url addon - requires['mojito-url-addon']

Note

To run older applications with Mojito v0.5.0 and later, you will need to
modify your controllers so that the ActionContext addons that are being
used are required. The most common addons are Config, Params, Url,
and Assets.