There is a function that returns a value for the key I specified.
function l(key){
let selectedLang = window.localStorage.getItem('language') || lang.default;
return lang[selectedLang][key];
}
const en = {
sidebar : {
"a" : "b",
}
}
l('sidebar') // function gives an object, its okey
But want to using like this, how can i do that.
l('sidebar.a') // Now its undifined