Closed eliottenos closed 7 years ago
The first thing I would mention is that you don't need to add a script tag for jQuery, the browser template does that for you. I would also mention that adding script tags is tricky with the browser template, is there another way you can add a map to your app?
this plugin seems to give me some good options for what I want it to do...how tricky @benjimelito?
You will need to add to the webpack file in the template, take a look at this if you'd like to give it a shot: https://webpack.github.io/docs/using-plugins.html
are you about for a real quick 1:1 to see if Im gonna continue with this or change course? @benjimelito
Sure, one sec and I'll come by
did you have any luck finding those previous issues re this plugin issue pal? @MicFin
@MicFin the above issue was a plugin that can be npm installed whereas by plugin, CSSMap, doesnt look like it can be installed. I've downloaded files provided by it and saved to my repo but still not sure how to have webpack preloaded when the templates are loaded. As far as I can see there needs to a third party plugin running it but not sure how?
Can you link to the docs for that plugin?
@cpearce31 cssmapsplugin.com/5/demo/
Do you get any console errors related to calling .CSSMap()? That might indicate whether the plugin is loading correctly.
yeah, Im getting this error in console
GET http://localhost:7165/assets/scripts/cssmap-europe/cssmap-europe.css
Uncaught ReferenceError: jQuery is not defined
at eval (eval at
@cpearce31 Im not even going to attempt to decode that function that has been provided. It continues along the lines of this
eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('(k($)
It appears then that the .CSSMap() function is getting called before jQuery is included. Have you tried calling that function from somewhere other than a Githubissues.
I've downloaded files required for the map plugin that Im using and requiring it from index.html
Docs say I need to implement the below in order to call the map files. I've pu tin my index.html but is not rendering on localhost. Would it make sure to add it all to a handlebars file and then call it from view.js upon sign in success?