New strategy structure
New ways of authentication can be added by following the next structure:
Create new passport strategy under
src/auth/[STRATEGY_NAME]Under it create file:
strategy.ts- The main file containing authenticate function logic
Import it into
/src/auth/passport.tsregister it using
passport.use()function
The strategy can contain as many files as it wants in its own folder, but needs to have the main strategy.ts file from which it exports the strategy object
Last updated