In my javascript i want something like this
SomeFunction(attribute){
var prev_rating = {{ u_list.attribute }};
}
The function can have three different inputs... beauty, wealth, age . So if I pass attribute = beauty to the function, var prev_rating should be set to
var prev_rating = {{ u_list.beauty }};
How can I achieve this ?