From ec7947979bb9287aec65d6f0fffefaff20daa9f6 Mon Sep 17 00:00:00 2001 From: Ben Alpert Date: Wed, 7 Oct 2015 12:50:59 -0700 Subject: [PATCH] Update downloads page for 0.14 (cherry picked from commit e1d4668fd5453157083665dbe034590b54ac83c0) --- docs/downloads.md | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/docs/downloads.md b/docs/downloads.md index c74df8be123d..f7b1a7fb6a0a 100644 --- a/docs/downloads.md +++ b/docs/downloads.md @@ -4,7 +4,7 @@ title: Downloads layout: single --- Download the starter kit to get everything you need to -[get started with React](/react/docs/getting-started.html). The starter kit includes React, the in-browser JSX transformer, and some simple example apps. +[get started with React](/react/docs/getting-started.html). The starter kit includes React and some simple example apps.
@@ -52,16 +52,17 @@ All scripts are also available via [CDNJS](https://cdnjs.com/libraries/react/). ## npm -If you're using an npm-compatible packaging system like browserify or webpack, you can use the `react` package. After installing it using `npm install react` or adding `react` to `package.json`, you can use React: +We recommend using React from npm with a bundler like [browserify](http://browserify.org/) or [webpack](https://webpack.github.io/). You can use the `react` and `react-dom` packages. After installing it using `npm install --save react react-dom`, you can use: ```js -var React = require('react-dom'); -ReactDOM.render(...); +var React = require('react'); +var ReactDOM = require('react-dom'); +ReactDOM.render(, ...); ``` -If you'd like to use any [add-ons](/react/docs/addons.html), use `var React = require('react/addons');` instead. +Each of the [add-ons](/react/docs/addons.html) lives in its own package. -**Note:** by default, React will be in development mode. To use React in production mode, set the environment variable `NODE_ENV` to `production`. A minifier that performs dead-code elimination such as [UglifyJS](https://github.com/mishoo/UglifyJS2) is recommended to completely remove the extra code present in development mode. +**Note:** by default, React will be in development mode. To use React in production mode, set the environment variable `NODE_ENV` to `production` (using envify or webpack's DefinePlugin). A minifier that performs dead-code elimination such as [UglifyJS](https://github.com/mishoo/UglifyJS2) is recommended to completely remove the extra code present in development mode. ## Bower