My question is really simple but I have not been able to find an answer to this.
Currently I have this :
const {email, firstname, lastname, isAdmin} = decodeToken(token);
const user = {email, firstname, lastname, isAdmin};
I’m looking for a way to shorten this chunk of code into a single line. I tried different combinations but none worked.