'Is there a downside to disabling create-react-app's SKIP_PREFLIGHT_CHECK?
I've installed eslint as a dev dependency on my create-react-app project. I'm doing this to
1) run eslint as a pre-commit check via husky and lint-staged
2) extend CRA's eslint with airbnb and prettier lint configs
I got the warning:
Manually installing incompatible versions is known to cause hard-to-debug issues ...
I just wanted to know if there's actually any real risk to having eslint manually installed? Or can I just "safely ignore" this warning? (via SKIP_PREFLIGHT_CHECK=true)
Solution 1:[1]
CRA projects scan the dependency tree for version mismatches issues, warning the developers about them to fix. SKIP_PREFLIGHT_CHECK=true skips this scan, so you may have version mismatches in your project without any advice. IMO you have 3 options:
Use SKIP_PREFLIGHT_CHECK=true with the possibility of a false positive
(NOT recommended) Eject your react project so that you can be responsible for managing all the package versions in it. This is probably not what you want and will likely lead to bigger future problems.
(I'd go for this one) Check if you really need to override the CRA package version. I've already worked on some projects with Airbnb eslint and prettier and never had this warning.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Gabriel Marques |
