In regular MVC, this is a generic pattern that has getter methods on the model that compute commonly received data. For example:
class User {
var firstName;
var lastName;
getFullName() {
return firstName + " " + lastName;
}
}
Suppose the JSON server response is {'firstName': "Bob", "lastName": "Smith"}.
In regular Flux, you can put such a method (getFullName ()) in your store (for example, Alt solves this by allowing you to use "exportPublicMethods" in your store).
In Redux, I'm not sure where this getFullName () method will work, given that it recommends using regular javascript objects inside your states (i.e., in my example, only firstName and lastName will be saved, the way to generate the resulting full name).
What would be the best / easiest way to do this?
Thanks!