How to use a google map api in a Firefox extension, if Firefox prohibits the attenuation of the CSP

(Minysav) #1

when you create a firefox extension, and if you want your extension to be installed from mozilla AMO, your extension should be without external js-files, only local js-files, all libraries must be local. In my extension, I use the Goole Map API, and all calls to Google Map Api have blocked the CSP from the manifest. I repeat my question: how to use the GOOGLE MAP API in the Firefox extension.

(Martin Giger) #2

You can change the CSP to allow connecting (connect-src) the Google Maps API. See

You must bundle the API library, if you want to use that, however.

(Minysav) #3

in connect-src all connections are allowed. google maps js script loads more js-files for work. but CSP (script-src) blocks the loading of new external scripts. if I save all google-maps js files locally, they do not work after a few days.