-
-
Notifications
You must be signed in to change notification settings - Fork 26.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Forbid Webpack loader syntax in imports
Enable no-webpack-loader-syntax rule in eslint-config-react-app.
- Loading branch information
Showing
6 changed files
with
12 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,7 +17,7 @@ If you want to use this ESLint configuration in a project not built with Create | |
First, install this package, ESLint and the necessary plugins. | ||
|
||
```sh | ||
npm install --save-dev eslint-config-react-app [email protected] [email protected] [email protected] eslint-plugin-import@1.12.0 [email protected] [email protected] | ||
npm install --save-dev eslint-config-react-app [email protected] [email protected] [email protected] eslint-plugin-import@2.0.0 [email protected] [email protected] | ||
``` | ||
|
||
Then create a file named `.eslintrc` with following contents in the root folder of your project: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -174,7 +174,7 @@ Then add this block to the `package.json` file of your project: | |
Finally, you will need to install some packages *globally*: | ||
|
||
```sh | ||
npm install -g [email protected] [email protected] [email protected] [email protected] eslint-plugin-import@1.12.0 [email protected] [email protected] | ||
npm install -g [email protected] [email protected] [email protected] [email protected] eslint-plugin-import@2.0.0 [email protected] [email protected] | ||
``` | ||
|
||
We recognize that this is suboptimal, but it is currently required due to the way we hide the ESLint dependency. The ESLint team is already [working on a solution to this](https://github.com/eslint/eslint/issues/3458) so this may become unnecessary in a couple of months. | ||
|