How to implement dependecy for not global module
I have an application in which I should include several bootstrap modules, so I have a bootstrap.js module: require('bower_components/bootstrap/js/bootstrap-tab')...
View ArticleRe : How to implement dependecy for not global module
That is the proper way to set the dependency. Probably you want to set up a path for your bootstrap: paths: { "bootstrap/*.js": "bower_components/bootstrap/js/bootstrap-*.js" } Then you can simple...
View ArticleRe : How to implement dependecy for not global module
And if these modules wheren't global what would be the way to set their deps?
View ArticleCan you bind a view over existing html?
http://stackoverflow.com/questions/26957835/can-can-js-bind-over-existing-html In backbone, instead of a template, you can give a selector and bind the events straight to that html: Can you do the same...
View ArticleRe : How to implement dependecy for not global module
First thinkg, this does not work: meta: { "bootstrap/*": { deps: ["jquery"] } } This works (still need to specify deps for each module): meta: { "bootstrap/tab": {deps: ["jquery"]},...
View ArticleRe : Can you bind a view over existing html?
What style of event binding do you mean? You can do it using jquery binding style for example. Please, show the code.
View ArticleQuestion on event cancelation or replacement
Using the drag event: $('.tileDiv').on('draginit', function (ev, drag) { ... }); I would like to disable dragging and ensure that the event bubbles to the parent element (which happens to be a...
View ArticleRe : Can you bind a view over existing html?
The problem here is the definition of the "view" between frameworks. Can's closer to an MVC in that sense and the "View" part is always about a template. The "controller" (can.Control) is the one you...
View ArticleBind and events understanding
Hello, everyone! Firstly, CanJS is really awesome. Thanks for this work. I try write first realtime app and have few newbie question about events in model. I have this code: $(function(){...
View ArticleRe : Bind and events understanding
The example does or does not work? Recipe . bind ( "destroyed" , function (){ console . log ( "a recipe destroyed" ); });
View ArticleRe : Bind and events understanding
This code from example in docs: Recipe = can.Model.extend({ destroy : "DELETE /collection/{id}", findOne : "GET /collection/{id}" },{}); Recipe.bind("destroyed", function(){...
View ArticleRe : Bind and events understanding
Destroy seems to be working if you are getting console.logs. Can you clarify what you mean? Are the example's "destroyed" events firing, but you are not seeing the request server side?
View ArticleRe : Bind and events understanding
Exactly. "recipe.destroy()" does not send DELETE query. This can be seen in the console. There's only a GET request . In the database there is no change . Moreover , making...
View ArticleRe : Bind and events understanding
I'm not sure what is going wrong. This certainly works and is heavily tested. Is your server sending back an id for the GET request?
View ArticleRe : Bind and events understanding
Yes. For example, code returns findOne and log: Recipe = can.Model.extend({ destroy : "DELETE /collection/{id}", findOne : "GET /collection/{id}"},{}); Recipe.findOne({id: 121}, function(recipe){...
View ArticleRe : Bind and events understanding
I found the problem . She was on the server side , the method GET {id} returns an array rather than a single record. I received [{bla: 'bla'}] instead of {bla: 'bla'}, so a direct call destroy() did...
View ArticleDoes FuncUnit Support jasmine 2.1?
Hi, does funcunit support jasmine 2.1? I really love both of them.
View ArticleSPA starter/development tools comparison
Hi group, I'm working on some research into things that provide opinion and automation for SPA development. I thought that it would be nice to include CanJS projects in a comparison I have made of...
View Article