@acdlite/react 中文文档教程
react
一个 npm 包,让你立即访问 React, 也不需要 JSX 转换器。 这对于您 想要browserify
你的模块使用 <代码>反应。
注意: 默认情况下,React 将处于开发模式。 开发版本包括关于常见错误的额外警告,而生产版本包括额外的性能优化并删除所有错误消息。
要在生产模式下使用 React,请将环境变量 NODE_ENV
设置为 production
。 建议使用 UglifyJS 等执行死代码消除的压缩器,以完全删除开发模式中存在的额外代码。
Example Usage
var React = require('react');
react
An npm package to get you immediate access to React, without also requiring the JSX transformer. This is especially useful for cases where you want to browserify
your module using React
.
Note: by default, React will be in development mode. The development version includes extra warnings about common mistakes, whereas the production version includes extra performance optimizations and strips all error messages.
To use React in production mode, set the environment variable NODE_ENV
to production
. A minifier that performs dead-code elimination such as UglifyJS is recommended to completely remove the extra code present in development mode.
Example Usage
var React = require('react');