
Passwordless authentication with magic links for Passport.js.
Passport-magic-login is a passwordless authentication solution for Passport.js that allows users to sign up and log in without the need for passwords. It offers support for magic links sent via email, SMS, or any other preferred method. This user-interface-agnostic tool handles secure token generation, expiration, and confirmation. Originally implemented by Tobias Lins for Splitbee, it was later extracted for Feedback Fish.
npm install passport-magic-login
const passport = require('passport');
const MagicLoginStrategy = require('passport-magic-login').Strategy;
passport.use(new MagicLoginStrategy());
app.post('/auth/login', passport.authenticate('magiclogin'), (req, res) => {
res.send('Successfully authenticated using magic link');
});
Passport-magic-login offers a secure and convenient way for users to authenticate without passwords. By utilizing magic links for authentication, this tool simplifies the user experience while ensuring secure token management. With easy installation and setup, it provides a seamless solution for implementing passwordless authentication in web applications.

Express.js is a simple Node.js framework for single, multi-page, and hybrid web applications.
TypeScript is a superset of JavaScript, providing optional static typing, classes, interfaces, and other features that help developers write more maintainable and scalable code. TypeScript's static typing system can catch errors at compile-time, making it easier to build and maintain large applications.