I have locale storage values that I would like to change but the problem is the values are object and I want to change "lang" property inside depends on the language preference of user.
That is how my local storage looks like Key (_I18N_config) and value {"lang":"en","JSON":{"All fields are required": "You have to fill in all fields"}}
If it was not in this type and it was just language string inside like "en" I would use localStroge.removeItem("_I18N_config") and then localStorage.setItem("_I18N_config","ger") to change language options. But I can not figure out how to react lang property to use this approach.
I am using it in React.js by the way. Thanks in advance!