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
ERROR in node_modules/@sentry/utils/dist/misc.d.ts(1,23):
TS2688: Cannot find type definition file for 'node'.
ERROR in /node_modules/@sentry/utils/dist/misc.d.ts(16,45):
TS2304: Cannot find name 'NodeModule'.
These can be resolved by either including @types/node in your package.json file or by making a file in a typeRoots directory named node.d.ts with the following contents:
declare module "node"{interfaceNodeModule{}// this ns may no longer be needed as of 5.0.7namespaceNodeJS{exporttypeGlobal=any}}
It seems strange that a browser library would rely on node typedefs, but these errors do not seem to occur in a more vanilla Typescript/Webpack setup. So it's possible there's nothing to fix here, but hopefully the above notes might be useful to others who encounter this issue.
The text was updated successfully, but these errors were encountered:
Package + Version
@sentry/browser
@sentry/node
raven-js
raven-node
(raven for node)@sentry/utils
Version:
Description
The browser package relies on:
@sentry/utils/dist/misc.d.ts
which in turn relies on node type definitions:This causes the following errors when used in conjunction with the Fork TS Checker Webpack Plugin:
These can be resolved by either including
@types/node
in your package.json file or by making a file in atypeRoots
directory namednode.d.ts
with the following contents:It seems strange that a browser library would rely on node typedefs, but these errors do not seem to occur in a more vanilla Typescript/Webpack setup. So it's possible there's nothing to fix here, but hopefully the above notes might be useful to others who encounter this issue.
The text was updated successfully, but these errors were encountered: