This is a migrated thread and some comments may be shown as answers.

MVVM suggestion

0 Answers 41 Views
MVVM
This is a migrated thread and some comments may be shown as answers.
Andrey
Top achievements
Rank 1
Andrey asked on 26 Mar 2012, 01:29 PM
Hello,

Will it be useful to have functionality similar to converters in Silverlight?
I am thinking about ability to have function which could convert value on set.
This could add  flexibility to the framework.
Something like:

var viewModel = kendo.observable({
            currencyAmount: 100.0,
            currencyText: {
 get: function () {
   var value = viewModel.get("currencyAmout");
   // convert to string and return converted formatted value.
},
 set: function (value) {
   // convert from string.
   viewModel.set("currencyAmout", amount);
}}
});


No answers yet. Maybe you can help?

Tags
MVVM
Asked by
Andrey
Top achievements
Rank 1
Share this question
or