Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
logout () {
netlifyIdentity.logout()
this.user = null
}
}
return new Promise((resolve, reject) => {
netlifyIdentity.logout();
netlifyIdentity.on('logout', () => {
resolve();
});
});
}
mounted () {
const netlifyIdentity = require("netlify-identity-widget")
netlifyIdentity.logout()
this.$router.push('/')
}
}
logout = callback => {
netlifyIdentity.logout();
netlifyIdentity.on('logout', () => {
this.setState({ user: null });
});
};
onClick={() => netlifyIdentity.logout()}
>