Skip to content

[BUG] 3.0.0 typescript compiler: Could not find a declaration file for module 'passport-strategy' #606

@rskvazh

Description

@rskvazh

To Reproduce

  1. npm install passport passport-saml @types/passport
  2. tsc

Got error:

node_modules/passport-saml/lib/passport-saml/strategy.d.ts:1:46
error TS7016: Could not find a declaration file for module 'passport-strategy'. '/Users/rskvazh/Projects/SpatialChat/spatialchat-universe/node_modules/passport-strategy/lib/index.js' implicitly has an 'any' type.
  Try `npm i --save-dev @types/passport-strategy` if it exists or add a new declaration (.d.ts) file containing `declare module 'passport-strategy';`

1 import { Strategy as PassportStrategy } from "passport-strategy";
                                               ~~~~~~~~~~~~~~~~~~~
Found 1 error.

Expected behavior

npm i --save-dev @types/passport-strategy fixed the error and successfully compiled, but I think this should be fixed in a passport-saml package.

Environment

  • Node.js version: v14.15.1
  • passport-saml version: 3.0.0
  • typescript: 4.3.2

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions