CORS request for CDN

Hi everybody,
I am a newbie and i’m trying to write an application using stealjs.
when I tried to load a module from a cdn i get the ‘Access-Control-Allow-Origin’ issue.
to do this i setup the following stealjs config param:

"steal": {
"paths" : {
  "google-maps": "https://maps.googleapis.com/maps/api/js"
}

for instance with google maps, i set up this module name and then in the component js file i add:

import google from "google-maps";

since i get that stealjs uses ajax call for the importing procedure, how can i configure it to allow me cors?

thanks for the support.

sorry, problem solved.
the requested resource is missing the header for the cors request.
thanks.

1 Like