Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to disable all checking for given file(s)?

I have some vendored JS libraries in a project, and I want to disable all ESLint checking for these files.

I've looked at the documentation and it describes how to disable checking via inline comments, e.g.

/* eslint-disable */

..but I would rather not touch the files, and configure ESLint via e.g. a local .eslintrc file. How to disable all checking as above, via such a file, is not described in the documentation.

Is it possible, and if so what would the .eslintrc file look like? It would be OK to disable all checking in a given directory.

like image 659
Dan Avatar asked Oct 11 '25 09:10

Dan


1 Answers

You can look at this answer from a similar question.

Basically you should add a .eslintignore file to your project's root directory and specify the files and directories you want to ignore like so:

.eslintignore file:

build/*.js
config/*.js
bower_components/foo/*.js

Also look at this section from the official ESLint docs

like image 126
Mor Paz Avatar answered Oct 13 '25 22:10

Mor Paz