adobe / helix-eslint-config

Eslint config used in helix projects.
Apache License 2.0
2 stars 11 forks source link

Suggest to forbid shadowing of global variables #59

Open dominique-pfister opened 3 years ago

dominique-pfister commented 3 years ago

Every now and then, I embarrassingly add a process function in a non-class file (e.g. an OpenWhisk action) that should process some input. This happily shadows the process global object in that file, leaving me baffled for some time until I find the problem.

Is there a reason we don't forbid shadowing global variables in:

https://github.com/adobe/helix-eslint-config/blob/3960a51666bed6c16f4a6556049ae4a52019ef10/index.js#L57-L59

by adding:

          builtinGlobals: true,