Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@Naouak
Created January 31, 2012 20:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Naouak/1712729 to your computer and use it in GitHub Desktop.
Save Naouak/1712729 to your computer and use it in GitHub Desktop.
Model Bug
YUI({
combine: false,
base: "/yui3/build/"
}).use("app","handlebars","jsonp",function(Y){
/**
* Article Model
**/
var Article = Y.Base.create("article",Y.Model,[],{
idAttribute: 'articleId'
},{
ATTRS: {
articleId: {value:null},
title: {value: null},
text: {value: null}
}
});
var a = new Article({
articleId: 1,
title: "foo",
text: "bar"
});
Y.log(a);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment