Browse Source

Fix the HTML for package management (#7656)

main
Kite 9 years ago
committed by Paul O’Shannessy
parent
commit
c16355138c
  1. 12
      docs/09.2-package-management.md

12
docs/09.2-package-management.md

@ -27,11 +27,11 @@ ReactDOM.render(
``` ```
Configure [babel](https://babeljs.io/) with a `.babelrc` file: Configure [babel](https://babeljs.io/) with a `.babelrc` file:
```json ```json
{ "presets": ["react"] } { "presets": ["react"] }
``` ```
> Note: > Note:
> >
> If you are using ES2015, you will want to also use the `babel-preset-es2015` package. > If you are using ES2015, you will want to also use the `babel-preset-es2015` package.
@ -67,19 +67,16 @@ new webpack.DefinePlugin({
Update your HTML file as below: Update your HTML file as below:
```html{8,12} ```html{9}
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<meta charset="UTF-8" /> <meta charset="UTF-8" />
<title>Hello React!</title> <title>Hello React!</title>
<script src="build/react.js"></script>
<script src="build/react-dom.js"></script>
<!-- No need for Babel! -->
</head> </head>
<body> <body>
<div id="example"></div> <div id="example"></div>
<script src="build/helloworld.js"></script> <script src="bundle.js"></script>
</body> </body>
</html> </html>
``` ```
@ -120,4 +117,3 @@ bower install --save react
## Using master ## Using master
We have instructions for building from `master` [in our GitHub repository](https://github.com/facebook/react). We have instructions for building from `master` [in our GitHub repository](https://github.com/facebook/react).

Loading…
Cancel
Save