I am looking for quick way to get an item from the Mozilla localStorage based on partial knowledge of an unique key. I have the following structure defined as the key : value
UUID1 : "BLABLABLA": UUID2 : Value
Where the key part looks like this for example:
ca4417f4-f83b-11eb-bf45-ffc420139ccb:BLABLABLA:e1d26c40-f83b-11eb-81c0-fbcc16bf6bdb
Value is just a long string.
What would be the fastest way to find a SINGLE key from localStorage based on only one of the two UUIDs i.e. either UUID1 or UUID2, then obtain the full key string and then use
localStorage.getItem to return it's value
maybe using Object.entries(localStorage)?
a code example would be really appreciated?