-
Notifications
You must be signed in to change notification settings - Fork 50.5k
Expose some more addons #745
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Also -- I could land |
|
These are pretty safe but I'm still a little bit concerned about supporting these. I know we've said addons is dangerous and we'll change it at anytime, but I'm afraid we're going to see more copypasta of things that aren't supported. So I'd like us to make sure we harden our APIs before exposing them as much as possible. Again, these are probably fine (then event hub is the one I'm nervous about) so I think it's fine here |
|
|
|
I'm good with it, letting @zpao do the final accept |
|
Yea, it's more about the case where a component you include injects an event plugin and that's totally outside your control. We're moving quickly into the world where people are using React and we're not having that close contact we had for the first few months. We're not seeing all the ways the uses are unfolding and I'm just getting a bit nervous is all. Feel free to go for it. |
|
I like rAF batching and I like add-ons but I wish we didn't have a React with add-ons build. It seems so final and official. It should be easy to expose these. They're really all candidates to be in the core. It's more of a alpha extensions build. We should take a page out of the old MooTools playbook and allow custom downloads: http://mootools.net/core/ |
|
I'm regularly sending people towards DOMContainer which has a small yet useful API but we don't provide it. That would be a great addition to addons. |
|
I wonder if we should add |
|
|
|
I was gonna do it for |
|
I don't think it makes sense to expose |
|
I think we could open-source Instagram's fake Should we add |
|
This pull request is getting out of hand. Let's open a separate pull request per module. It should export the module AND add a documentation for it. We'll be able to discuss on whether we should export modules on a per module basis instead of everyone at once. |
This adds some more addons.
If this is accepted we will update the documentation to have instructions for using addons from
npmas well as from the premade builds. If usingnpmyou shouldrequire('react/lib/ReactTransitionGroup')rather than usingreact/addonsso you don't pull in extra dependencies.I think we definitely need the event plugins and TestUtils. I wasn't sure about
ImmutableObjectandStateSetters, but they seem like good ideas.I considered adding
ReactUpdates.injectionin there for pluggable batching strategies andReactPerf, but this already works in npm today (react-raf-batchingandreact-profiler) and I wanted to keep this as constrained as possible.If someone signs off on this I'll stack a commit on top with docs (or do it in a new PR, either way).