question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

package installed via npm doesnt have type definition

See original GitHub issue

Hi typings is missing when we install via npm

npm install stackdriver-errors-js

Screenshot 2021-08-24 at 5 59 41 PM

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
k0walikcommented, Aug 26, 2021

I think there is a mismatch between script entry point and types file definition. If we rename the definition file to stackdriver-errors.d.ts (and make corresponding update in package.json) it works as expected.

I created PR for that: https://github.com/GoogleCloudPlatform/stackdriver-errors-js/pull/98

1reaction
sterencommented, Oct 1, 2021

I’m pushing to npm now

Read more comments on GitHub >

github_iconTop Results From Across the Web

NPM Package doesn't have Types - node.js - Stack Overflow
The quick way is to create a globals.d.ts file and add the line: declare module "express-bearer-token";.
Read more >
How to Install Types for Packages -- newline - Fullstack.io
The biggest repository with type declarations is DefinitelyTyped. It contains type declarations for packages like React, Redux, Mobx, and many ...
Read more >
types packages are not installed as expected #4489 - GitHub
My observation is that cause of this issue is yarn considers * as newest version and @types packages have often dependencies versioned as...
Read more >
Typescript Typings: The Complete Guide: @types Compiler ...
Type definitions are available and shipped together with the compiler itself; A library does not ship with type definitions, but they can be ......
Read more >
npm-install - npm Docs
Description. This command installs a package and any packages that it depends on. If the package has a package-lock, or an npm shrinkwrap...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found