Jan 05 2021 01:34 PM
I have created SPFx extension (not a webpart, in case it makes any difference) and trying to add jQuery but its not doing it. I have installed it into package with
npm install --save @types/jquery
added
"externals": {
"jquery": "./src/extensions/tracker2/js/JQuery_3.5.1.js"
},
into config.json ,
import * as jQuery from 'jquery';
into MyPackage.ts
But still getting " jQuery is not defined " when trying to use jQuery in my code.
Thanks
Jul 20 2021 05:15 AM
Hi @RomanRomych.
Did you ever work out what was going wrong with this?
I have exactly the same issue and have burned hours trying to find a solution, all without any success.