I am trying to pass a string from redux to a parameter, I am not sure about the syntax, "lang" is a string 100%
const About = () => {
const lang = useSelector((state) => state.counter.lang);
const about = {
ru: {
aboutTitle: "rus",
},
tr: {
aboutTitle: "tr",
},
en: {
aboutTitle: "en",
},
};
return (
<h2>{about.lang.aboutTitle}</h2>
);
};