learn hapi — Create a JWT Utility

When using JSON web tokens in your application, you’ll find JWT related implementations in different places.

For example, creating a new JWT is part of a login route handler. Authenticating an incoming JWT takes place in an authentication strategy. Refreshing a JWT, JWT logout, or token blacklisting are use cases where you’ll surely introduce JWT handling.

That’s why you should create a JWT utility that consolidates the handling. Rely on the interface provided by the JWT utility and create yourself reliable helper methods.

hapi Series Overview


Continue reading

University Enrollment Required

Future Students benefit from value packed videos and tutorials.

Enroll to receive exclusive content or sign in if you’re already a Future Student.

Enroll me for $15/mo

Explore the Library

Find interesting tutorials and solutions for your problems.