These are chat archives for canjs/canjs

16th
May 2016
Sunil George
@georgesunil81
May 16 2016 13:33
Good morning all A quick question - I want to implement two way binding using CanJS and Stache. Currently, I am able to have a one-way binding from the model (scope) to the stache template using {{key}}. Could someone help me with binding from the stache back to the model? For example, I have the following input field that I am rendering with stache -
<input id="accountname" type="text" value = {{account_name}}>
account_name is on the scope that I am passing to the stache. If I change the value of account_name on the scope, it updates the value in the view automatically. But, it is not working vice versa. Could someone help?
Kevin Phillips
@phillipskevin
May 16 2016 15:43
Try <input id="accountname" type="text” {($value)}= "account_name”> @georgesunil81
{(prop)}=“key” for two-way binding
$value for the DOM value property
check out https://canjs.com/docs/can.view.bindings.html for some examples
Sunil George
@georgesunil81
May 16 2016 15:49
Ah, thanks @phillipskevin . I was doing like <input id="accountname" type="text” {($value)}= {{account_name}}>. I guess that is why it was not working for me.
Trying it now.
Yahoo! it worked. Thanks @phillipskevin
Thanks a ton.
Justin Meyer
@justinbmeyer
May 16 2016 16:30
Request for topics for this week's community meeting: http://forums.donejs.com/t/donejs-community-meeting-2016-05-20/271
Adam L Barrett
@BigAB
May 16 2016 17:12
Is there a way to determine if something is either a compute of just a function? Like isCompute() or something?
Kevin Phillips
@phillipskevin
May 16 2016 17:17
.isComputed I think
Justin Meyer
@justinbmeyer
May 16 2016 17:57
yes .. isComputed
Thomas Sieverding
@Bajix
May 16 2016 18:57
Your subdomain SSL certificates are setup improperly
The certs expired on May 8th