Typescript intellisense
See original GitHub issueHiya folks!
Tried to use this in a project and if I try and add a product using addItem
and then try to map over the items afterwards, Typescript doesn’t seem to understand any of the other props that I passed in with my object. It is only doing intellisense on the Item
interface Item {
id: string;
price: number;
quantity?: number;
itemTotal?: number;
[key: string]: any;
}
Seems to fully ignore [key: string]: any;
Is this expected behaviour?
Issue Analytics
- State:
- Created 2 years ago
- Comments:8 (6 by maintainers)
Top Results From Across the Web
TypeScript Programming with Visual Studio Code
IntelliSense shows you intelligent code completion, hover information, and signature help so that you can write code more quickly and correctly. TypeScript ......
Read more >VS Code: enable javascript intellisense in typescript project
Is there a way to enable intellisense for Javascript files in a Typescript project? If I import a function from a javascript package...
Read more >JavaScript and TypeScript Intellisense - XrmToolkit.com
XrmToolkit provides both JavaScript and TypeScript files that allow you to have all the intellisense features in Visual Studio for your CRM forms....
Read more >JavaScript IntelliSense - Visual Studio - Microsoft Learn
IntelliSense based on TypeScript declaration files ... Because JavaScript and TypeScript are now based on the same language service, they are able ...
Read more >Is there any way to activate IntelliSense for TypeScript files in ...
as an in-browser code editor, can github.dev activate the sophisticated kind of IntelliSense for .ts files that the desktop version of ...
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 FreeTop 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
Top GitHub Comments
I realise after this that with TypeScript you can have generic components, so could be worth making a Provider that accepts a generic
To add onto this, I would like this to be updated as well:
There is no
setItems: (items: Item[]) => void;
in here. I’ve added PR for this fix, let me know if its good to go because its my first ever code fix on open source.