We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Bind whole object to control, not property by property

Hi,

I used syncfusion control a lot with Durandal, knockout and there was very easy to bind whole object to the control.
Example:

View:

       <input data-bind="ejDropDownList: dropDownMultiple" />


Model:

     self.dropDownMultiple = {
            dataSource: ko.observableArray([
                { text: "Surname1", value: "value1" },
                { text: "Surname2", value: "value2" },
                { text: "Surname3", value: "value3" },
                { text: "Surname4", value: "value4" },
                { text: "Surname5", value: "value5" }
            ]),
            fields: { text: "text", value: "value" }, 
            enabled: self.isReadonly,
            allowMultiSelection: true,
            multiSelectMode: "visualMode",
        }

Is there any chance to we do that with Angular 2 binding, or we need to bind every property separately ?

Regards,
Milos

1 Reply

AS Abinaya Subbiah Syncfusion Team May 16, 2017 09:36 AM UTC

Hi Milos, 

Thanks for contacting Syncfusion support. 

Currently we doesn’t have support to passing model object with Angular components. But, we considered your valuable feedback and planned to provide support for the same. Please log on to our support website to check for further updates.  


Regards, 
Abinaya S 


Loader.
Up arrow icon