Where/how to include external JS files that can't/shouldn't be grabbed and stored locally


#1

Let’s say I sign up for some service and they require me to reference their script like so:

<script src="//cdn.someservice.com/js/dynamicJsScript"></script>

How can I include this in my app? I’d like a solution that’s router-agnostic.


#2

I believe you can put links to external js files in the <head> </head> part of your template


#3

I tried that before and it didn’t work.


#4

you can use $.getScript .
http://www.meteorsnippets.com/blog/add-external-scripts-in-meteor


#5

Thanks. I knew about that, but was wondering if there was another way. This is a script that has to be loaded extremely in the page loading process. But I’ll give this a shot and see if it works out.