These are chat archives for canjs/canjs

2nd
Mar 2018
Julian
@pYr0x
Mar 02 2018 11:36
today is donejs contributor meeting?
can i join?
Yeswanth Raghav T
@tyraghav
Mar 02 2018 12:29
Hi AllTwo way binding of
Hi All, can anyone help me please
Mohamed Cherif Bouchelaghem
@cherifGsoul
Mar 02 2018 12:31
@tyraghav what is your question?
@tyraghav for two-way binding <input value:bind="vmProp" >
Yeswanth Raghav T
@tyraghav
Mar 02 2018 12:36
I have two way binded a model in a can.control.extend to a child-prop in a can.component.extend . Value change in attr of model from can.component to can.control is working fine, but control to component is not working
Can you please help me
Note : i am using can 2.3
canjs 2.3
Mohamed Cherif Bouchelaghem
@cherifGsoul
Mar 02 2018 12:40
what is the binding syntax you are using?
Yeswanth Raghav T
@tyraghav
Mar 02 2018 12:42
<comp {(cmodel)}="pmodel"/>
Where pmodel is inside can.control and pmodel is in viewModel of can.component
Mohamed Cherif Bouchelaghem
@cherifGsoul
Mar 02 2018 12:43
this is the child to parent binding
Yeswanth Raghav T
@tyraghav
Mar 02 2018 12:44
How can I make a two way binding
Mohamed Cherif Bouchelaghem
@cherifGsoul
Mar 02 2018 12:44
try to add another binding for parent to child <comp {(cmodel)}="pmodel" {($pmodel)}="cmodel"/>
Yeswanth Raghav T
@tyraghav
Mar 02 2018 12:48
It did not work
Mohamed Cherif Bouchelaghem
@cherifGsoul
Mar 02 2018 12:53
@tyraghav It's been a long time since I used v2.3 maybe you just need <comp {($cmodel)}="pmodel" />
Yeswanth Raghav T
@tyraghav
Mar 02 2018 13:06
It did not work either
Is it okay to bind a complete model instead of single attribute of model ?
Mohamed Cherif Bouchelaghem
@cherifGsoul
Mar 02 2018 13:23
@tyraghav can you make a simplified version of your use case in a jsbin?
Viktor Busko
@Lighttree
Mar 02 2018 13:32

@AntonProkofyev it's modifying the object where?

@justinbmeyer The question was, why url behavior mutates data that we sent in request body. The point is that if we have url like:

api/entity/{id}

and payload like

{
    id: 11,
    fieldOne: 'someValue',
    fieldTwo: 'anotherValue'
}

after makeAjax this object mutates to:

{
   fieldOne: 'someValue',
   fieldTow: 'anotherValue'
}

because {id} is presented in url. And this feels strange regardless is it ok or no send id in payload. The point is that server might expect to see it in payload, but url behavior removes it implicitly before send.

It modifies payload, because of true in this line:
https://github.com/canjs/can-connect/blob/master/data/url/url.js#L363

if we pass true to replaceWith it will remove fields from original object.

alexey1986
@alexey1986
Mar 02 2018 13:33
Screenshot_1.png
Could you please help me with understanding of this issue?
I have two input type="file", when I click on second, this issue appears...
alexey1986
@alexey1986
Mar 02 2018 13:45
I do not use any delegates
Guido Smeets
@gsmeets
Mar 02 2018 15:26
does anyone have some info on what changed between can 2.3.28 and 2.3.33? can't find anything in the changelogs
Kevin Phillips
@phillipskevin
Mar 02 2018 15:37
@gsmeets we started using release notes like https://github.com/canjs/canjs/releases/tag/v2.3.33
not all are filled out. I'll try to update them with what I can figure out
I take it back... they are all filled out
they don't have a ton of info, but all link back to the PR
Justin Meyer
@justinbmeyer
Mar 02 2018 16:20
contributors meeting starting in 10: https://www.youtube.com/watch?v=Z3CV0zmMFoE
Julian
@pYr0x
Mar 02 2018 16:20
can i join?
i dont have a calendar reminder anymore
Mohamed Cherif Bouchelaghem
@cherifGsoul
Mar 02 2018 16:22
@pYr0x you didnt get an email?
Matthew Phillips
@matthewp
Mar 02 2018 16:24
we got you julian
Viktor Busko
@Lighttree
Mar 02 2018 17:51
@phillipskevin regarding slowness of forms guide I'm not sure that this is ok solution, but lazy loading of iframes may help and quick. I think you can insert urls to examples as soon as we scroll page, and examples will load their dependencies not on page load but as we scroll.
Kevin Phillips
@phillipskevin
Mar 02 2018 17:53
thanks
I'm going to open an issue now and throw out some ideas
Julian
@pYr0x
Mar 02 2018 18:32
@justinbmeyer my teaser proposal: yes, you canJS
Matthew Phillips
@matthewp
Mar 02 2018 18:32
hah
Julian
@pYr0x
Mar 02 2018 18:33
  • you can write great user experience web apps
  • you can use innovative features
  • you can structure your codebase better
etc.. :)
... you are the maker and we can help you
Julian
@pYr0x
Mar 02 2018 18:39
This message was deleted
Matthew Phillips
@matthewp
Mar 02 2018 18:48
cutesy stuff like that is fun... but it is different from a library's core message
with donejs it kind of makes sense though, "Your app. Done." says what donejs is about
I'm not sure that can puns do the same.