You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
TSC error when trying to compile for deployment using node v18.18.2. node_modules/@virgilsecurity/e3kit-node/dist/types/src/index.d.ts:2:29 - error TS7016: Could not find a declaration file for module 'virgil-crypto/dist/node.es.js'.
Looks like the KeyPairType exported has a any type and is making TSC complain.
Expected behavior
Expect KeyPairType export to have type.
Screenshots
> tsc
node_modules/@virgilsecurity/e3kit-node/dist/types/src/index.d.ts:2:29 - error TS7016: Could not find a declaration file for module 'virgil-crypto/dist/node.es.js'. '/Users/admin/app/functions/node_modules/virgil-crypto/dist/node.es.js' implicitly has an 'any' type.
If the 'virgil-crypto' package actually exposes this module, try adding a new declaration (.d.ts) file containing `declare module 'virgil-crypto/dist/node.es.js';`
2 export { KeyPairType } from 'virgil-crypto/dist/node.es.js';
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Found 1 error in node_modules/@virgilsecurity/e3kit-node/dist/types/src/index.d.ts:2
The text was updated successfully, but these errors were encountered:
@chinesehemp Hello! Sorry for being late, you do not need to import KyPairType from /dist/node.es.js
This will work, because .es files working not like modules! import { KeyPairType } from 'virgil-crypto';
@chinesehemp Hello! Sorry for being late, you do not need to import KyPairType from /dist/node.es.js This will work, because .es files working not like modules! import { KeyPairType } from 'virgil-crypto';
Hi @rstp-god thanks for getting back to me. I'm not trying to import KeyPairType from virgil-crypto. Maybe I didn't word it correctly. The issue is Typescript compiler is warning me of an error and I traced it back to the source where the type had the any value.
> tsc
node_modules/@virgilsecurity/e3kit-node/dist/types/src/index.d.ts:2:29 - error TS7016: Could not find a declaration file for module 'virgil-crypto/dist/node.es.js'. '/Users/admin/app/functions/node_modules/virgil-crypto/dist/node.es.js' implicitly has an 'any' type.
If the 'virgil-crypto' package actually exposes this module, try adding a new declaration (.d.ts) file containing `declare module 'virgil-crypto/dist/node.es.js';`
2 export { KeyPairType } from 'virgil-crypto/dist/node.es.js';
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Found 1 error in node_modules/@virgilsecurity/e3kit-node/dist/types/src/index.d.ts:2
Describe the bug
TSC error when trying to compile for deployment using node v18.18.2.
node_modules/@virgilsecurity/e3kit-node/dist/types/src/index.d.ts:2:29 - error TS7016: Could not find a declaration file for module 'virgil-crypto/dist/node.es.js'.
Package dependencies
Looks like the KeyPairType exported has a
any
type and is making TSC complain.Expected behavior
Expect
KeyPairType
export to have type.Screenshots
The text was updated successfully, but these errors were encountered: