As I'm setting up ESLint for the first time, I'm a little confused about how it deals with globals.
I've got 40+ js files, (one js file per page in a CRM like application), and some of them are quite long, like 3-4k+ lines. And these JS files share most of their functions in a common file I've named "core.js", which gets included on all pages.
Looking at https://eslint.org/docs/user-guide/configuring#specifying-globals, it looks like it wants me to specify every single function and variable that's used from core.js
in my current file, order.js
. That just wouldn't be an option, since there's bound to be 50+ global functions/variables that I use, and that list is very subject to change.
Is there not a way to tell ESLint that everything in core.js
is global to this file? And on the flip side, it's also telling me that the functions in my core.js
aren't ever being used.