Quantcast
Channel: JavaScriptMVC Forum
Browsing all 3491 articles
Browse latest View live

Two way data binding

I see how with live binding I can have my model update my view.  But I am not seeing how I can internal to my template tie user input to my model.  Do I still need to put code logic inside my...

View Article


Re : Is it possible to associate data with a div in an EJS template?

Thanks, this worked, I had a typo initially but it worked like a champ!

View Article


Re : Two way data binding

Two-way binding is not baked into CanJS, so yes you would have to put logic in your Control to update your model.However, thecountofzero has created a two-way binding plugin called Tracker that you...

View Article

Re : Interaction between Controllers

Probably youre right. May I ask, how you would generally include an api into javascriptmvc and how you would seperate the logic? The problem is, that the FB-SDK functionality is used in very different...

View Article

Re : Testing CanJS Web Apps

Thank you for your reply. I would like to know how to test a can controller. How do i trigger events in a controller.I'm thinking of mocking my controller's dependencies and trigger all my controller...

View Article


Re : Testing CanJS Web Apps

FuncUnit allows you to interact with your app exactly how a user would. It has the ability to simulate click, dblclick, type, drag, etc, etc.Custom events can be triggered using can.trigger or $.trigger.

View Article

Re : Testing CanJS Web Apps

I tried this but can.trigger returns the following jquery error: Uncaught TypeError: Cannot read property 'type' of undefined define(["can"],function(can){ var HelloWorldController = can.Control({...

View Article

Re : Testing CanJS Web Apps

This worked :$(controller).trigger("click"); but not this:  controller.trigger("click");

View Article


Re : Testing CanJS Web Apps

An instance of a Control would not have a trigger method unless you created one.The event handler you have in your Control will not work because there is no CSS selector. All of this is documented...

View Article


Live Binding ejs with can.observe does not update

I have used live binding in a similar way before, but this time it is not working.I load an ejs file with only:<%= this.myData.attr('counter'); %>I have an observable like this:this.myData = new...

View Article

jmvc 3.3 Generate/control is broken

I just cloned so this is off of master.Try 1:/js jmvc/generate/control Modules.Orders      Modules.Orders/Modules.Orders/Modules.Orders.html      Modules.Orders/Modules.Orders/Modules.Orders.jsjs:...

View Article

Re : Testing CanJS Web Apps

Thank you very much sir. I did look threw the well documented API for CanJS. There is a weird problem occurring when declaring a new controller with routing capabilities via the AMD library of...

View Article

Re : Live Binding ejs with can.observe does not update

Can you create a fiddle

View Article


Re : Live Binding ejs with can.observe does not update

Maybe I should start using fiddle....While doing my own test, I found something:I am selecting several elements for the view:$('.myTemplateElements').html(.....I now see that only the last element in...

View Article

Re : Live Binding ejs with can.observe does not update

Don't know, but wouldn't think so.Just created a fiddle demo'ing this issue:http://jsfiddle.net/thecountofzero/qYdwR/630/

View Article


Re : steal build not pulling in all files/dependencies

the machine/process doing the build was separate from the source of the app.

View Article

Re : Live Binding ejs with can.observe does not update

It's not intentional, but expected. There's not a great way to fix this either. can.view('dummyEJS', {        person: person    })That returns an already-live documentFragment.  jQuery is doing some...

View Article


Re : jmvc 3.3 Generate/control is broken

generators other than app and scaffold are currently not working../js jmvc/generate/scaffold cookbook/models/recipe

View Article

Re : jmvc 3.3 Generate/control is broken

I'll have the others fixed tomorrow night.

View Article

Re : Live Binding ejs with can.observe does not update

I agree hacking jQuery is not a good idea.I can adress the items one by one...It is a single-page-app that has legal information in several places. You can switch your country and/or language. The...

View Article
Browsing all 3491 articles
Browse latest View live