Reputation: 3446
I'm new to all of these nodejs, typescript, auth0.
i get this error, when i try to use express-jwt-authz in one sample app:
src/server.ts:4:22 - error TS7016: Could not find a declaration file for module 'express-jwt-authz'. 'C:/Code/Nodejs_practice/nodeHttp/node_modules/express-jwt-authz/lib/index.js' implicitly has an 'any' type.
Try npm install @types/express-jwt-authz
if it exists or add a new declaration (.d.ts) file containing declare module 'express-jwt-authz';
4 import jwtAuthz from 'express-jwt-authz';
is there any workaround for this?
Upvotes: 0
Views: 495
Reputation: 1705
Since that module that doesn't have typings, you can use via:
const jwtAuthz = require("express-jwt-authz");
Upvotes: 1