I am currently learning how to use React, and I'm having problems running my React app using npm start. Specifically, I get an error which says - "Create React App requires a dependency: "babel-loader": "8.1.0"". The instructions given in the error message on how to fix this are as follows:
To fix the dependency tree, try following the steps below in the exact order:
1. Delete package-lock.json (not package.json!) and/or yarn.lock in your project folder.
2. Delete node_modules in your project folder.
3. Remove "babel-loader" from dependencies and/or devDependencies in the package.json file in your project folder.
4. Run npm install or yarn, depending on the package manager you use.
I tried doing this, but when I ran npm install, I got the following:
added 1880 packages, and audited 1881 packages in 19s
153 packages are looking for funding
  run `npm fund` for details
58 vulnerabilities (16 moderate, 40 high, 2 critical)
To address issues that do not require attention, run:
  npm audit fix
To address all issues (including breaking changes), run:
  npm audit fix --force
Then, when I ran npm start again, I got the same error.
I realize there is another thread on this here already: Create React App requires a dependency: "babel-loader": "8.1.0". But none of the suggestions on the thread have worked. For example, I tried creating a .env file with SKIP_PREFLIGHT_CHECK=true, but what I got was:
 .
.
So I'm wondering what I can do to solve the problem. I would really appreciate it if someone could figure it out. This is my package.json file, if it helps:
{
  "name": "task-app",
  "version": "0.1.0",
  "private": true,
  "dependencies": {
    "@testing-library/jest-dom": "^5.14.1",
    "@testing-library/react": "^11.2.7",
    "@testing-library/user-event": "^12.8.3",
    "react": "^17.0.2",
    "react-dom": "^17.0.2",
    "react-scripts": "4.0.3",
    "web-vitals": "^1.1.2"
  },
  "scripts": {
    "start": "react-scripts start",
    "build": "react-scripts build",
    "test": "react-scripts test",
    "eject": "react-scripts eject"
  },
  "eslintConfig": {
    "extends": [
      "react-app",
      "react-app/jest"
    ]
  },
  "browserslist": {
    "production": [
      ">0.2%",
      "not dead",
      "not op_mini all"
    ],
    "development": [
      "last 1 chrome version",
      "last 1 firefox version",
      "last 1 safari version"
    ]
  }
}
 
    