americanexpress / react-albus

✨ React component library for building declarative multi-step flows.
Apache License 2.0
1.1k stars 89 forks source link

Make peerDependencies future proof #115

Closed sonnyp closed 2 years ago

sonnyp commented 2 years ago

Installing react-albus on a React 17 project fails.

This doesn't require any action when a new version of React is released but react-albus could break if React has breaking changes.

This is what react-phone-number-input does https://gitlab.com/catamphetamine/react-phone-number-input/-/blob/af70a8b05c238076056aa1be528ae7808bc4b31a/package.json#L263

An other option is to keep adding React versions, this is what react-redux does https://github.com/reduxjs/react-redux/blob/7882dfcf780567aab8a64f52e028a65aadad9d10/package.json#L45-L46 but given react-albus hasn't seen an update on npm since 2017 - the first approach seems more pragmatic.

    "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",

but please note I have only tested with React 17

CLAassistant commented 2 years ago

CLA assistant check
All committers have signed the CLA.