Skip to content

Add react-dom as a peer-dependency #657

@tryggvigy

Description

@tryggvigy

test-utils/ is exported as part of the public API of this module in package.json exports.
It imports from react-dom import { act } from 'react-dom/test-utils'; but react-dom is only declared as a devDependency. This can cause issues in bundlers. I think changing peerDependencies to

"peerDependencies": {
  "react": "^15.0.0 || ^16.0.0 || ^17.0.0 || ^18.0.0"
+ "react-dom": "^15.0.0 || ^16.0.0 || ^17.0.0 || ^18.0.0"
},

should fix this issue

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions