knockout.mapping icon indicating copy to clipboard operation
knockout.mapping copied to clipboard

'Include' option is not working properly

Open GChernikov opened this issue 11 years ago • 2 comments

After doing: var mapping = { 'include': ['someField1', 'someField2'] } ko.mapping.fromJS(newData, mapping, myViewModel);

myViewModel contains all fields from newData object, not only 'someField1' and 'someField2'. Other mapping options (ignore, copy, observe) works OK.

GChernikov avatar Oct 16 '13 14:10 GChernikov

I have the exact same problem!

aupp avatar Jan 14 '14 16:01 aupp

@aupp @GChernikov Although this issue is quite old I'm willing to fix it if still around. If possible please provide a jsfiddle or a test. I tried with the version in my fork and didn't encounter any issues with this option.

crissdev avatar Feb 23 '15 16:02 crissdev