Skip to content

Conversation

@heysamtexas
Copy link
Contributor

Just thought it would be nice to know how to use this using require() statements.

@facebook-github-bot
Copy link
Contributor

Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. In order for us to review and merge your code, please sign up at https://code.facebook.com/cla - and if you have received this in error or have any questions, please drop us a line at [email protected]. Thanks!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We do mention it super briefly in the npm readme, but it's not obvious. So let's do it. I'd like to tweak the wording though (you have to use require in Node, so there's no if about it).

Maybe something along the lines of this?

When using the react package in from npm, you can simply require('react/addons') instead of require('react') to get React with all of the addons.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 sounds good. Let's go with that

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent. Want to update this PR or would you prefer I just add it in? (no need for me to steal credit, it was your idea!)

@facebook-github-bot
Copy link
Contributor

Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Facebook open source project. Thanks!

zpao added a commit that referenced this pull request Sep 10, 2014
Added extra explanation for require() statements
@zpao zpao merged commit 76d6481 into facebook:master Sep 10, 2014
@heysamtexas heysamtexas deleted the patch-1 branch September 12, 2014 14:29
zpao added a commit that referenced this pull request Sep 24, 2014
Added extra explanation for require() statements
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants