score:0

as hugefunwoo says

next.js will replace process.env.customkey with 'my-value' at build time. trying to destructure process.env variables won't work due to the nature of webpack defineplugin.

const { jwt_secret } = process.env 

this will return undefind so i had to replace it by

const jwt_secret = process.env.jwt_secret

Related Query

More Query from same tag