I am facing problem with dynamic selector. Here is my code
var data = {
'one': {'value': '50,60,70,80'},
'two': {'value': '10,20,30,40'}
}
var eachValue = data.one.value.split(',');
That code is working correcting but i need dynamic selector for one two so if i code like
var select = 'one';
var eachValue = data.select.value.split(',');
its not working. its showing TypeError: data.select is undefined error. So how can i use dynamic selector within this. Thanks