# react-sh

> A super easy shell for react app.

Latest version **0.6.5** (published 2017-05-03) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-sh
pnpm add react-sh
yarn add react-sh
bun add react-sh
```

Provides the command `react-sh`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.6.5 |
| Published | 2017-05-03 |
| First published | 2016-11-06 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 16 |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 4 |
| Author | @heineiuo |
| Maintainers | heineiuo |

## Links

- npm: https://www.npmjs.com/package/react-sh
- Repository: https://github.com/heineiuo/react-sh
- Homepage: https://github.com/heineiuo/react-sh#readme
- Issues: https://github.com/heineiuo/react-sh/issues
- npm.io page: https://npm.io/package/react-sh

## Dependencies (16)

- [yargs](https://npm.io/package/yargs.md) ^6.6.0
- [express](https://npm.io/package/express.md) ^4.14.0
- [webpack](https://npm.io/package/webpack.md) ^2.2.1
- [babel-core](https://npm.io/package/babel-core.md) ^6.21.0
- [url-loader](https://npm.io/package/url-loader.md) ^0.5.7
- [file-loader](https://npm.io/package/file-loader.md) ^0.10.1
- [json-loader](https://npm.io/package/json-loader.md) ^0.5.4
- [babel-loader](https://npm.io/package/babel-loader.md) ^6.2.10
- [rucksack-css](https://npm.io/package/rucksack-css.md) ^0.8.6
- [babel-preset-react](https://npm.io/package/babel-preset-react.md) ^6.16.0
- [babel-preset-es2015](https://npm.io/package/babel-preset-es2015.md) ^6.18.0
- [babel-preset-stage-0](https://npm.io/package/babel-preset-stage-0.md) ^6.16.0
- [webpack-dev-middleware](https://npm.io/package/webpack-dev-middleware.md) ^1.10.0
- [webpack-hot-middleware](https://npm.io/package/webpack-hot-middleware.md) ^2.14.0
- [webpack-node-externals](https://npm.io/package/webpack-node-externals.md) ^1.5.4
- [webpack-system-register](https://npm.io/package/webpack-system-register.md) ^1.4.0

## Recent versions

- 0.6.5 (latest) — 2017-05-03
- 0.6.4 — 2017-02-25
- 0.6.3 — 2017-02-16
- 0.6.1 — 2017-02-16
- 0.6.0 — 2017-02-16
- 0.5.4 — 2017-02-16
- 0.5.3 — 2017-02-13
- 0.5.2 — 2017-02-12
- 0.5.1 — 2017-02-12
- 0.5.0 — 2017-02-12
- 0.4.0 — 2017-02-10
- 0.3.0 — 2017-01-16
- 0.2.1 — 2017-01-16
- 0.2.0 — 2017-01-16
- 0.1.0 — 2016-11-27
- … 1 more at https://npm.io/package/react-sh/versions

## README

# react-sh

## install

```bash
npm install react-sh --save-dev
#or
yarn add react-sh -D
```

## use

1. add start and build script to your package.json, like:

```json
...
{
  "start": "react-sh",
  "build": "react-sh --build --compress --production",
}
...
```

2. add react-dev.json to your project root path, please see format from `react-dev.json` in this project.

```json5
{
  // 编译目标，可以0个或多个
  "targets": [
    {
      // 如果为TRUE，则这个target不起作用
      "disable": false,
      "origin": false,

      // 输出的package的名字
      "key": "smile-web",
      
      // 已废弃
      "template": "src/index.html",
      
      // 入口文件的相对路径
      "filename": "src/index.js",
      
      // 输出目录的相对路径
      "distPath": "./dist",
      
      // 同webpack publicPath
      "publicPath": "//unpkg.com/smile-web@0.0.9/dist/",
      // 开发模式下的publicPath
      "devPublicPath": "http://127.0.0.1:8083/dist/",
      
      // 同webpack alias
      "alias": {
        "react": "react/dist/react.js",
        "react-dom": "react-dom/dist/react-dom.js"
      },
      /**
       * 同webpack externals 不需要webpack打包的package，一般是比较大的比如react之类的package，比如这里。
       * 也可以什么包都不加（推荐），直接去掉即可。
       */
      "externals": {
        "react": {
          "root": "React",
          "amd": "react",
          "commonjs": "react"
        },
      },
      // 是否打包为一个library
      "isLibrary": true
    }
  ],
  
  // 全局 是否使用.babelrc文件
  "useBabelrc": true,
  
  // 全局 开发模式下的public path(webroot)
  "devPublicPath": "./",
  
  // 全局 需要用babel编译的在node_modules目录里面的package
  "modulesNeedBabel": [
    "react-lang"
  ]
}
```

## peer dependencies

* react
* react-dom
* react-router
* react-router-redux
* redux
* redux-actions

---
_Source: https://npm.io/package/react-sh · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
