Open threepointone opened 7 years ago
Can't see much in there that would cause issues. Would it be workable to just strip PropTypes entirely using babel-plugin-transform-react-remove-prop-types? Then this would probably already work via preact/aliases
.
I'm using proptypes not for props, but for reading context vars. how would that work in preact? does preact expose all context vars by default?
Preact exposes all context by default, yup. Can safely strip :)
while it would be simple enough to use preact-compat and call it a day, I'd like to explore whether we can make a boutique preact build, and how much code the 2 variants could share.
Further, we're not really tied to react-router, any component that accepts a render function would do. So there's an opportunity to shave away bytes with a bespoke lib.
This is the react-specific file. I don't foresee too many issues, just have to work on it once rakt gets to somewhere stable.
//cc @developit