Closed sapegin closed 6 years ago
Just wanted to note that this issue is about using React 16 internally. Examples (can?) use the version of React you (as a developer) provide. What it means is you can use React 16 in examples right now, or use an older React version when the styleguidist
will use v16 internally.
Yes, it’s about making sure that Styleguidist itself will work with React 16 and will not print peer dependencies warning.
react-codemirror2 has got support for react 16
For react-icons
, see https://github.com/gorangajic/react-icons/issues/116 and https://github.com/gorangajic/react-icons/issues/117
For react-codemirror2
, see https://github.com/scniro/react-codemirror2/issues/15. Upgrading to v2.0.2+ should work. Any reason that particular package is pegged to v2.0.0 when all the others are more permissive? even just ~v2.0.0
would be sufficient to pick up bugfix releases.
Happy to submit a PR with the dep upgrades.
Any reason that particular package is pegged to v2.0.0 when all the others are more permissive?
I think it was because of #611, ^
should work fine now.
Happy to submit a PR with the dep upgrades.
@nwwells Please do it ;-)
Will do. I was recently made a contributor on https://github.com/gorangajic/react-icons so I'll work on resolving the issue there first and then get to this, hopefully today.
submitted #622 for review. I believe that's all that should be needed, but I need to test after the new react-icons release is published.
I'd like to work on adding a componentDidCatch()
handler -- mostly because I wanted to work with it a bit and learn how best to use it. @sapegin did you have thoughts on where it should be added/what should happen on error?
@tizmagik Sounds awesome! I’ll learn from you ;-)
We’re already catching errors in users’ components (each has a separate React root anyway) so I think we need a global componentDidCatch
handler to catch bugs in Styleguidist or user customizations (when users replace Styleguidist components). It could look similar to React error overlay and say something like “if you believe it’s a bug in Styleguidist, report it”.
react-icons marks support for react 16 as of 2.2.6.
Hey, it looks like the package.lock needs to be updated as well, will submit a PR for that soon.
updated react-icons in https://github.com/styleguidist/react-styleguidist/pull/628
I’ve removed react-modal and tweaked examples.
What's up with markdown-to-jsx
? It seems to work fine, no?
@tizmagik I think it is, let’s check it ;-)
Yea, I checked it out locally and it seemed to be working fine, but someone else could double-check I guess.
Verified that upgrading to v6.0.28 got rid of peer dependency warnings! Yay!
@nwwells Awesome! Then the only thing left is #631.
This issue will track React 16 compatibility. It seems to work fine but there are several peer dependency warnings.
Dependencies compatibility:
[x] React 16 final release
[x] Enzyme 3.0
[x] markdown-to-jsx — N/A (seems to work)
[x] react-codemirror2 —
no support[x] react-group —
N/A[x] react-icons —
[no support](https://github.com/gorangajic/react-icons/issues/103)[x]
react-modal — some issues (we use it only in examples)N/A means no reported issues.
No support means
peerDependencies
don’t allow React 16, may work otherwise.Styleguidist upgrade status:
npm install