TypeScript Definitions Issue
See original GitHub issueBecause of the recent change in TypeScript definitions (from namespace to type) in https://github.com/nbubna/store/commit/1ca5d1605bfdd8f1662317e8f7182f91d5075439, the package is now broken for TypeScript users. I’ve confirmed that store.set() and store.get() work as usually in JavaScript, but because store is now a type in the TS definitions, it can’t be used the same way. (Since our project is written in TS, the latest version of store breaks our builds.)
Is there a change to how we’re supposed to handle the package in TS? Or is this a bug? Either way, would really appreciate some help here.
Thank you!
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:21 (6 by maintainers)
Top Results From Across the Web
Documentation - Type Declarations - TypeScript
Built-in Type Definitions. TypeScript includes declaration files for all of the standardized built-in APIs available in JavaScript runtimes. This includes ...
Read more >Typescript: missing type definitions. · Issue #8642 - GitHub
I am opening this issue to report missing types when I notice that. Here is the first: Cookie options type does not have...
Read more >Problem with Typescript Definitions
I've tried reinstalling Typescript. I've tried invalidating the cache and restarting. My calls to the type definitions seem to be correct.
Read more >Cannot find name 'describe'. Do you need to install type ...
I'm using Visual Studio Code as my IDE and in my Angular project, and I had to comment-out/remove types in file tsconfig.json and...
Read more >@types/node - npm
TypeScript definitions for Node.js. Latest version: 18.11.18, last published: 3 days ago. Start using @types/node in your project by running ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Ok, 2.13.1 has been published. Thank you, again, for the help with this one! And sorry for the trouble.
Thank you, shirblc, for the test repo! And being willing to test. I think i was able to test too, using your repo. I checked it out was able to get the error, then manually tweak the store2 index.d.ts as i show above in the node_modules directory, and ran tsc again. It seems like it does the trick. So i think we’re good. I’ll get a bugfix release out asap.