Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
YUI: Post initialization of an extension
YUI.add(
"ep-data-user",
function (Y) {
var DataUser = Y.namespace("EP").DataUser = function (config) {
//Y.log("DataUser constructor");
this.after("initializedChange", this.post_initialization, this);
};
//
// these values should be overridden with defaults in the class
// using this extension
//
DataUser.ATTRS = {
data_user_parameters: {
value: null
}
};
DataUser.prototype = {
_data_user_data_mgr: null,
post_initialization: function () {
Y.log("DataUser::post_initialization");
Y.log("DataUser::post_initialization - this: " + this);
Y.log("DataUser::post_initialization - data_user_parameters: " + Y.dump(this.get("data_user_parameters")));
if (Y.Lang.isValue(this.get("data_user_parameters"))) {
// do stuff here...
}
}
};
},
"0.0.1",
{
requires: []
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment