Skip to content

node_modules/@types/react-native/globals.d.ts (36,15): Duplicate identifier 'FormData'. #33311

@rami-res-zz

Description

@rami-res-zz

If you know how to fix the issue, make a pull request instead.

how to reproduce:

  • Fresh install react app by command
    yarn create react-app my-app-ts --scripts-version=react-scripts-ts
  • add styled components
    yarn add styled-components
    yarn add -D @types/styled-components
  • import ThemeProvider to src/index.tsx and wrap to
import * as React from 'react';
import * as ReactDOM from 'react-dom';
import {ThemeProvider} from "styled-components";
import App from './App';
import './index.css';
import registerServiceWorker from './registerServiceWorker';

ReactDOM.render(
    <ThemeProvider theme={{}}>
        <App />
    </ThemeProvider>,
  document.getElementById('root') as HTMLElement
);
registerServiceWorker();
  • run build command:
    yarn start
  • Expected result:
    See the react app
  • Current result:

image

There is a lot of fails according to many definitions conflicts with lib.dom
image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions