INNER CODE UNIT · JavaScript

decodeJwt

chandankushwahaa/100xdevs_2.0 · 0-1/week03/assignments/02-jwt/index.js:68

function decodeJwt(token) {
    // Your code here
    //////////
    try {
        const decoded = jwt.decode(token)
        if (!decoded) {
            return false
        }
        return true;
    } catch (error) {
        return false
    }
    //////////
}


module.exports = {
  signJwt,

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…