Can you ignore a global variable such as OpenLayers from the config.json file?
I’ve been having to do this at the top of every class file:
/**
* @ignore(OpenLayers)
*/
I also tried this:
"lint" :
{
"lint-check" :
{
"allowed-globals" :
[
"OpenLayers"
]
}
},
but that doesn’t seem to do the trick. Thanks!
It really depends which Generator job you are running. Your second approach, adding OpenLayers to the config’s
lint/lint-check/allowed-globalsshould well serve you when runninggenerate.py lint.But in order to make it also relevant for compile jobs (source*, build), you need to inject the
lint-checkkey also to their configuration. Just fork this key out into a dedicated job definition, and then include it in the “worker” jobs, e.g. like this:Now all relevant jobs should honor the setting to ignore the OpenLayers global.