Could anyone help me solve my build errors. Trying to build aurelia app with gulp. But importing jquery doesn't work straight away.
import $ from 'jquery';
gives me an error
src\examples\datatablesExample.ts(1,8): error TS1192: Module '"jquery"' has no default export.
typings\jquery\jquery.d.ts(3210,13): error TS2403: Subsequent variable declarations must have the same type. Variable '$' must be of type 'cssSelectorHelper', but here has type 'JQueryStatic'.
So I'm importing jquery as follows
import * as $ from 'jquery';
Can anyone explain why some guys can import jquery straight away, but I can't? Also what is the second error about, is it something jquery has mixed up?
Just trying to figure out jspm with aurelia, jquery and other modules.
after you have installed jquery by
jspm install jquery
try to load jquery by
But ensure that you are in root dir of your project when you execute the jspm command. After installing i would suggest to make a clean and a gulp build command again before you use the methods.