Search code examples
node.jsfirebasegoogle-cloud-functionseslintfirebase-cli

Check ESLint warnings with Firebase CLI without deploying functions


I have a bunch of ESLint warnings that I want to resolve, but don't want to go through troubleshooting them by continuously deploying a function. Is there a Firebase CLI command that I can use to just check for errors/warnings?


Solution

  • You wouldn't use the Firebase CLI for this. Use npm instead. Notice in your package.json there a number of scripts that perform various tasks. You want to run the "lint" script.

    In your shell, change to the "functions" folder and run npm run lint. This will execute the named "lint" script defined in package.json.