js-model
js-model copied to clipboard
Work with models in your JavaScript
Is this project being maintained??
Hello. How can i remove an entire model collection when using local storage. Thanks
var Project = new Model('project', function(){ this.persistence(Model.REST, "api/projects"); }); var project = new Project({name:"testing12345"}); project.save(); It will send data like this : {project: {name: "testing12345"} } yet my backend expect...
I've added a bower file to integrate well into existing projects with bower support.
You should consider putting this library on Bower. I install Sammy.js from Bower and it looks like there is a lot of talk online about using these two libraries together....
Klass.destroy(instance, callback) and Klass.save(instance, callback). No API deprecations. Instance#destroy() and Instance#save() just delegate to class. Motives: allows me to save a model as part of a different collection, using the...
Starting this pull request to list what changes need to be made to the documentation for the V1 release. - [x] Collection#add isn't chainable in v1 - [ ] Listening...
Hi, I had a stab at adding the Model.Coerce that came up in the date serialization discussion. I've added integer, boolean, float and isoDate coercion as a start since that...
I have the basic implementations of validatesNumericalityOf, validatesPresenceOf, validatesFormatOf and validatesUniquenessOf, I also added a class method any(). Let me know what you think.
I use express js as backend, you could read several issues with application/json with no body. It's returns invalid json https://github.com/visionmedia/express/issues/1416