title: Duplicate identifier 'LibraryManagedAttributes' - Nothing seems to fix the issue
body: <p>I desperately need some help with a react dependencies problem. Whenever I try to run lint using npx eslint --format codeframe --ext .tsx --ext .jsx --ext .ts --ext .js app/client, I see linting errors coming from the node_modules directories, specifically, node_modules/@types/react/index.d.ts. Errors like Duplicate identifier 'LibraryManagedAttributes'..</p>
  <p>Researching the error, I am seeing answers on stack overflow etc saying to do things like:</p>
  <ul>
  <li>Reinstall @types/react</li>
  <li>Ensure versions of react, @types/react and @types/react-dom are all the same</li>
  <li>Remove package-lock.json and node-modules and run npm install again.</li>
  <li>Update typescript version.</li>
  <li>Add a resolutions field to package.json to manually specify the versions of @types/react  and @types/react-dom to use.</li>
  </ul>
  <p>Existing answers (which do not fix the problem)</p>
  <p><a href="https://stackoverflow.com/questions/52399839/duplicate-identifier-librarymanagedattributes">Duplicate identifier &#39;LibraryManagedAttributes&#39;</a>
  <a href="https://stackoverflow.com/questions/52323056/typescript-error-duplicate-identifier-librarymanagedattributes">TypeScript error: Duplicate identifier &#39;LibraryManagedAttributes&#39;</a>
  <a href="https://stackoverflow.com/questions/54664268/duplicate-identifier-librarymanagedattributes">Duplicate identifier &#39;LibraryManagedAttributes</a>
  <a href="https://stackoverflow.com/questions/52339225/react-typescript-2312-14-duplicate-identifier-librarymanagedattributes">React typescript (2312,14): Duplicate identifier &#39;LibraryManagedAttributes&#39;</a></p>
  <p>However, I have tried all of these things, but nothing at all is fixing the linter. I keep getting lint errors from node_modules/@types/react/index.d.ts.</p>
  <p>If anyone has any insight to this, I would be very greteful, as there is little else I can do at this point other than just turn the linter off.</p>
  <p>package.json:</p>
  <pre><code>  &quot;dependencies&quot;: {
      &quot;@apollo/client&quot;: &quot;^3.3.7&quot;,
      &quot;@babel/polyfill&quot;: &quot;^7.12.1&quot;,
      &quot;@babel/preset-react&quot;: &quot;^7.16.5&quot;,
      &quot;@babel/preset-typescript&quot;: &quot;^7.16.5&quot;,
      &quot;@sentry/browser&quot;: &quot;^6.4.0&quot;,
      &quot;@storybook/react&quot;: &quot;^6.4.9&quot;,
      &quot;@testing-library/react&quot;: &quot;^12.1.2&quot;,
      &quot;@typescript-eslint/eslint-plugin&quot;: &quot;^5.8.0&quot;,
      &quot;@typescript-eslint/parser&quot;: &quot;^5.8.0&quot;,
      &quot;clsx&quot;: &quot;^1.1.0&quot;,
      &quot;core-js&quot;: &quot;^3.18.3&quot;,
      &quot;cors&quot;: &quot;^2.8.5&quot;,
      &quot;country-list&quot;: &quot;^2.2.0&quot;,
      &quot;cross-fetch&quot;: &quot;^3.1.4&quot;,
      &quot;css&quot;: &quot;^3.0.0&quot;,
      &quot;css-loader&quot;: &quot;^3.5.3&quot;,
      &quot;cypress&quot;: &quot;^9.1.1&quot;,
      &quot;error-overlay-webpack-plugin&quot;: &quot;^0.4.1&quot;,
      &quot;eslint-config-prettier&quot;: &quot;^8.3.0&quot;,
      &quot;eslint-plugin-prettier&quot;: &quot;^3.4.1&quot;,
      &quot;eslint-plugin-react&quot;: &quot;^7.28.0&quot;,
      &quot;eslint-plugin-react-hooks&quot;: &quot;^4.3.0&quot;,
      &quot;express-http-proxy&quot;: &quot;^1.6.2&quot;,
      &quot;extract-css-chunks-webpack-plugin&quot;: &quot;^4.7.5&quot;,
      &quot;fastify&quot;: &quot;^2.10.0&quot;,
      &quot;fastify-http-proxy&quot;: &quot;^3.0.0&quot;,
      &quot;fastify-static&quot;: &quot;^2.5.0&quot;,
      &quot;graphql&quot;: &quot;^15.4.0&quot;,
      &quot;immer&quot;: &quot;^6.0.2&quot;,
      &quot;isomorphic-fetch&quot;: &quot;^3.0.0&quot;,
      &quot;libphonenumber-js&quot;: &quot;^1.8.5&quot;,
      &quot;lodash&quot;: &quot;^4.17.15&quot;,
      &quot;msw&quot;: &quot;^0.26.1&quot;,
      &quot;node-sass&quot;: &quot;^6.0.1&quot;,
      &quot;object-hash&quot;: &quot;^2.0.3&quot;,
      &quot;os-utils&quot;: &quot;0.0.14&quot;,
      &quot;puppeteer&quot;: &quot;^8.0.0&quot;,
      &quot;purgecss&quot;: &quot;^4.0.3&quot;,
      &quot;raw-loader&quot;: &quot;^4.0.2&quot;,
      &quot;react&quot;: &quot;^17.0.2&quot;,
      &quot;react-dom&quot;: &quot;^17.0.2&quot;,
      &quot;react-icons&quot;: &quot;^4.3.1&quot;,
      &quot;react-inlinesvg&quot;: &quot;^2.3.0&quot;,
      &quot;react-markdown&quot;: &quot;^7.0.1&quot;,
      &quot;react-redux&quot;: &quot;^7.2.5&quot;,
      &quot;react-test-renderer&quot;: &quot;^17.0.2&quot;,
      &quot;redux&quot;: &quot;^4.0.4&quot;,
      &quot;redux-thunk&quot;: &quot;^2.3.0&quot;,
      &quot;regenerator-runtime&quot;: &quot;^0.13.3&quot;,
      &quot;reselect&quot;: &quot;^4.0.0&quot;,
      &quot;reset-css&quot;: &quot;^5.0.1&quot;,
      &quot;resize-observer-polyfill&quot;: &quot;^1.5.1&quot;,
      &quot;sentry&quot;: &quot;^0.1.2&quot;,
      &quot;source-map-loader&quot;: &quot;^1.1.3&quot;,
      &quot;to-string-loader&quot;: &quot;^1.1.6&quot;,
      &quot;typescript&quot;: &quot;^4.5.4&quot;,
      &quot;unfetch&quot;: &quot;^4.2.0&quot;,
      &quot;uuid&quot;: &quot;^8.0.0&quot;
    },
    &quot;devDependencies&quot;: {
      &quot;@babel/core&quot;: &quot;^7.15.8&quot;,
      &quot;@babel/plugin-transform-runtime&quot;: &quot;^7.11.0&quot;,
      &quot;@babel/preset-env&quot;: &quot;^7.15.8&quot;,
      &quot;@storybook/addon-actions&quot;: &quot;^6.3.12&quot;,
      &quot;@storybook/addon-console&quot;: &quot;^1.2.3&quot;,
      &quot;@storybook/addon-essentials&quot;: &quot;^6.3.12&quot;,
      &quot;@types/jest&quot;: &quot;^27.0.2&quot;,
      &quot;@types/node&quot;: &quot;^14.14.14&quot;,
      &quot;@types/react-dom&quot;: &quot;^17.0.2&quot;,
      &quot;@types/supertest&quot;: &quot;^2.0.11&quot;,
      &quot;babel-eslint&quot;: &quot;^10.0.3&quot;,
      &quot;babel-jest&quot;: &quot;^27.3.1&quot;,
      &quot;babel-loader&quot;: &quot;^8.0.6&quot;,
      &quot;chai-colors&quot;: &quot;^1.0.1&quot;,
      &quot;cheerio&quot;: &quot;^1.0.0-rc.3&quot;,
      &quot;css&quot;: &quot;^3.0.0&quot;,
      &quot;eslint&quot;: &quot;^7.18.0&quot;,
      &quot;eslint-import-resolver-alias&quot;: &quot;^1.1.2&quot;,
      &quot;eslint-loader&quot;: &quot;^4.0.2&quot;,
      &quot;eslint-plugin-import&quot;: &quot;^2.22.1&quot;,
      &quot;eslint-plugin-jsx-a11y&quot;: &quot;^6.4.1&quot;,
      &quot;file-loader&quot;: &quot;^4.2.0&quot;,
      &quot;fork-ts-checker-webpack-plugin&quot;: &quot;^1.5.1&quot;,
      &quot;html-webpack-exclude-assets-plugin&quot;: &quot;0.0.7&quot;,
      &quot;html-webpack-plugin&quot;: &quot;4.0.0-alpha&quot;,
      &quot;jest&quot;: &quot;^27.3.1&quot;,
      &quot;mini-css-extract-plugin&quot;: &quot;^0.8.0&quot;,
      &quot;prettier&quot;: &quot;^2.2.1&quot;,
      &quot;sass-loader&quot;: &quot;^10.1.0&quot;,
      &quot;storybook&quot;: &quot;^6.1.14&quot;,
      &quot;supertest&quot;: &quot;^6.1.3&quot;,
      &quot;svg-inline-loader&quot;: &quot;^0.8.0&quot;,
      &quot;ts-loader&quot;: &quot;^8.0.14&quot;,
      &quot;url-loader&quot;: &quot;^2.2.0&quot;,
      &quot;wait-on&quot;: &quot;^6.0.0&quot;,
      &quot;webpack&quot;: &quot;^4.41.2&quot;,
      &quot;webpack-bundle-analyzer&quot;: &quot;^3.6.0&quot;,
      &quot;webpack-cli&quot;: &quot;^3.3.9&quot;,
      &quot;webpack-dev-server&quot;: &quot;^3.9.0&quot;,
      &quot;webpack-format-messages&quot;: &quot;^2.0.5&quot;,
      &quot;webpack-merge&quot;: &quot;^4.2.2&quot;,
      &quot;whatwg-fetch&quot;: &quot;^3.6.2&quot;
    },
    &quot;resolutions&quot;: {
      &quot;@types/react&quot;: &quot;^17.0.2&quot;
    }
  </code></pre>
  <p>.eslintrc:</p>
  <pre><code>  {
      &quot;extends&quot;: [&quot;eslint-config-airbnb&quot;],
      &quot;parser&quot;: &quot;@typescript-eslint/parser&quot;,
      &quot;ignorePatterns&quot;: [
        &quot;**/node_modules/**&quot;,
        &quot;node_modules&quot;,
        &quot;**/node_modules&quot;,
        &quot;**/@types/react/**&quot;,
        &quot;@types/react&quot;,
        &quot;**/*.d.ts&quot;
      ],
      &quot;parserOptions&quot;: {
        &quot;ecmaVersion&quot;: 2018,
        &quot;sourceType&quot;: &quot;module&quot;,
        &quot;ecmaFeatures&quot;: {
          &quot;jsx&quot;: true
        }
      },
      &quot;env&quot;: {
        &quot;browser&quot;: true,
        &quot;node&quot;: true
      },
      &quot;settings&quot;: {
        &quot;react&quot;: {
          &quot;version&quot;: &quot;detect&quot;
        }
      },
      &quot;overrides&quot;: []
    }
  </code></pre>
  <p>Babel config:</p>
  <pre><code>  module.exports = {
      presets: [
        '@babel/preset-react',
        '@babel/preset-typescript',
        [
          '@babel/preset-env',
          {
            useBuiltIns: 'usage',
            corejs: 3,
            shippedProposals: true,
          },
        ],
      ],
      ignore: [/\/core-js/, /\/webpack/],
      sourceType: 'unambiguous',
      plugins: ['macros'],
      env: {
        test: {
          presets: [
            '@babel/preset-react',
            '@babel/preset-typescript',
            [
              '@babel/preset-env',
              {
                shippedProposals: true,
                targets: { node: 'current' },
              },
            ],
          ],
          plugins: ['@babel/plugin-transform-runtime'],
          sourceType: 'unambiguous',
          plugins: ['macros'],
        },
      },
    };
  </code></pre>