Using only available req.query objects as keys in redis

Viewed 208

I have a MERN application, and I am using redis to implement caching. I have a router with req.query (localhost:3000/persons?name=john&lastname=doe&age=18) With Redis i want to use only available objects inserted in url, I mean if in url we insert name key will be name; if we insert the 3 object keys will be : name, lastname, age. there is various combination and i don't how i know to implement that i mean how to implement generic way to implement this or condition.

0 Answers
Related