0

When I run the command tsx watch src/bootstrap/server.ts I get this error:

 TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string or an instance of Buffer or URL. Received undefined

the error points to this line of code:

const jwtKey = fs.readFileSync(process.env.JWT_PUBLIC_KEY as string)

This has never thrown any errors before and everything I find online praises how easy tsx is so I must be doing something wrong.

Currently this repo uses nodemon and runs with no problem, its just slow to recompile.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.