-
-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to include jquery with typings #231
Comments
|
I got an error: PS: I downloaded jquery.d.ts manually from DefinetlyTyped and put this files to typings folder |
Should I use an ambient option? I have read in blakeembrey blog, that he advises against using ambient modules http://blakeembrey.com/articles/2015/11/state-of-typescript-packaging/ |
Look at the end of |
@RemKolomna can you share what you're doing right now. To install from DefinitelyTyped, you can do As for the additional issues, I know Angular has some binding so the global |
Indeed it does, I solved it by changing L3200 from:
to
The problem with this solution is, if |
Awesome, makes sense. What we can do in Typings is turn jQuery into an external module and allow installation, just need someone to maintain that 👍 As for the reset, you don't have to use Typings to install it. I usually make a |
Thanks! I added jquery to custom_typings, change to export = jQuery; and everything is ok now! |
you should use: typings install dt~jquery --global |
@qSoft I got: [default] C:\Projects\xx\yy\typings\globals\jquery\index.d.ts:3227:13 |
I'm not using typings anymore, just including |
Did you add the jquery types to your tsconfig as well? |
Yes, sorry, forgot about that. |
I added jquery to this starter using instructions from this link #215
But I have TypeScript errors like this:
TS2339: Property 'ajax' does not exist on type 'cssSelectorHelper'. or
TS2339: Property 'mousedown' does not exist on type 'ElementFinder'.
In all places where I access $ variable
I have tried adding jquery.d.ts to files section of tsconfig.json (just after line "typings/main.d.ts"), but the problem persist. How to fix it?
The text was updated successfully, but these errors were encountered: