---
order: 1
title: 寮€濮嬩娇鐢�
type: 鍏ラ棬
---
# 寮€濮嬩娇鐢�

### 蹇€熷紑濮�
```
1. **鍒�濮嬪寲鐜閰嶇疆**
  
    绗竴娆¤繍琛岄渶瑕侀厤缃幆澧�.

2. **鍏�闅�椤圭洰**

    `git clone svn://182.92.218.9:3691/project/JSJG/Server/dev/front/branches/bbdweb`.

3. **杩愯瀹夎鍛戒护**

    `npm install or yarn install`.

4. **鍚姩椤圭洰**

    `npm start`.

5.  **鐜閰嶇疆** 
    
    闇€瑕� node4.0 浠ヤ笂璇疯嚜琛岄厤缃€佺洿鎺ユ渶鏂扮増涔熷彲浠ュ彧鏄竴涓幆澧�

```

### 鐩綍缁撴瀯
```bash
鈹溾攢鈹€ mock                     # 鏈湴妯℃嫙鏁版嵁
鈹溾攢鈹€ public
鈹偮犅� 鈹斺攢鈹€ favicon.ico          # Favicon
鈹溾攢鈹€ src
鈹偮犅� 鈹溾攢鈹€ assets               # 鏈湴闈欐€佽祫婧�
鈹偮犅� 鈹溾攢鈹€ common               # 搴旂敤鍏敤閰嶇疆锛屽瀵艰埅淇℃伅
鈹偮犅� 鈹溾攢鈹€ components           # 涓氬姟閫氱敤缁勪欢
鈹偮犅� 鈹溾攢鈹€ constants            # 甯搁噺鏂囦欢
鈹偮犅� 鈹溾攢鈹€ e2e                  # 闆嗘垚娴嬭瘯鐢ㄤ緥
鈹偮犅� 鈹溾攢鈹€ layouts              # 閫氱敤甯冨眬
鈹偮犅� 鈹溾攢鈹€ models               # dva model
鈹偮犅� 鈹溾攢鈹€ routes               # 涓氬姟椤甸潰鍏ュ彛鍜屽父鐢ㄦā鏉�
鈹偮犅� 鈹溾攢鈹€ services             # 鍚庡彴鎺ュ彛鏈嶅姟
鈹偮犅� 鈹溾攢鈹€ utils                # 宸ュ叿搴�
鈹偮犅� 鈹溾攢鈹€ theme.js             # 涓婚閰嶇疆
鈹偮犅� 鈹溾攢鈹€ index.ejs            # HTML 鍏ュ彛妯℃澘
鈹偮犅� 鈹溾攢鈹€ index.js             # 搴旂敤鍏ュ彛
鈹偮犅� 鈹溾攢鈹€ rollbar.js           # 婊氬姩鏉¢厤缃�
鈹偮犅� 鈹溾攢鈹€ index.less           # 鍏ㄥ眬鏍峰紡
鈹偮犅� 鈹斺攢鈹€ router.js            # 璺敱鍏ュ彛
鈹溾攢鈹€ tests                    # 娴嬭瘯宸ュ叿
鈹溾攢鈹€ README.md                # 璇存槑鏂囨。
鈹溾攢鈹€ .editorconfig            # ide
鈹溾攢鈹€ .eslintrc                # 浠g爜瑙勮寖
鈹溾攢鈹€ .gitignore               # git閰嶇疆
鈹溾攢鈹€ .roadhogrc               # dva閰嶇疆
鈹溾攢鈹€ jsconfig                 # js閰嶇疆鍜宭int閰嶅悎鐢�
鈹溾攢鈹€ .roadhogrc.mock          # mock鏁版嵁
鈹溾攢鈹€ .stylelintrc             # 鏍疯瘯lint
鈹斺攢鈹€ package.json             # 鍖呯鐞�
```



## 鎶€鏈偣

妗嗗姞鐢ㄥ埌鐨勬妧鏈偣灏辨槸涓嬮潰鎻愪緵鐨�:

| **鏍囬** | **鎻忚堪** |**浜嗚В鏇村**|
|----------|-------|---|
|  [React](https://facebook.github.io/react/)  |   蹇€燂紝鍙粍鍚堢殑瀹㈡埛绔粍浠�.    | [Pluralsight Course](https://www.pluralsight.com/courses/react-flux-building-applications)  |
|  [Redux](http://redux.js.org) |  瀹炴柦鍗曞悜鏁版嵁娴佸拰涓嶅彲鍙樼殑鐑彲閲嶆柊鍔犺浇瀛樺偍 [Facebook's Flux](https://facebook.github.io/flux/docs/overview.html).| [Getting Started with Redux](https://egghead.io/courses/getting-started-with-redux), [Building React Applications with Idiomatic Redux](https://egghead.io/courses/building-react-applications-with-idiomatic-redux), [Pluralsight Course](http://www.pluralsight.com/courses/react-redux-react-router-es6)|
|  [React Router](https://github.com/reactjs/react-router) | react鍓嶇璺敱瑙e喅鏂规 | [Pluralsight Course](https://www.pluralsight.com/courses/react-flux-building-applications) |
|  [Babel](http://babeljs.io) |  灏咵S6缂栬瘧涓篍S5,缂栧啓浠g爜鍙互鐢ㄦ渶鏂扮殑javascript璇硶.     | [ES6 REPL](https://babeljs.io/repl/), [ES6 vs ES5](http://es6-features.org), [ES6 Katas](http://es6katas.org), [Pluralsight course](https://www.pluralsight.com/courses/javascript-fundamentals-es6)    |
| [Webpack](https://webpack.js.org) | 灏唍pm鍖呭拰鎴戜滑鐨凧S鎹嗙粦鍒颁竴涓枃浠朵腑銆� 鍖呮嫭閫氳繃鐑噸鏂板姞杞� [react-transform-hmr](https://www.npmjs.com/package/react-transform-hmr). | [Quick Webpack How-to](https://github.com/petehunt/webpack-howto) [Pluralsight Course](https://www.pluralsight.com/courses/webpack-fundamentals)|
| [Browsersync](https://www.browsersync.io/) | 杞婚噺绾у紑鍙慔TTP鏈嶅姟鍣紝鏀寔澶氳澶囦笂鐨勫悓姝ユ祴璇曞拰璋冭瘯. | [Intro vid](https://www.youtube.com/watch?time_continue=1&v=heNWfzc7ufQ)|
| [Jest](https://facebook.github.io/jest/) | 鑷姩鍖栨祴璇曪紝鍐呯疆棰勬湡鏂█鍜岀敤浜嶥OM娴嬭瘯鐨勯叾锛屾棤闇€娴忚鍣ㄤ娇鐢∟ode. | [Pluralsight Course](https://www.pluralsight.com/courses/testing-javascript) |
| [TrackJS](https://trackjs.com/) | JavaScript閿欒璺熻釜. | [Free trial](https://my.trackjs.com/signup)|  
| [ESLint](http://eslint.org/)| 妫€鏌S銆� 鎶ュ憡璇硶鍜屾牱寮忛棶棰樸€� 浣跨敤eslint-plugin-for棰濆鐨勫弽搴旂壒瀹氱殑linting瑙勫垯 [eslint-plugin-react](https://github.com/yannickcr/eslint-plugin-react) 鎴栭澶栫殑React鐗瑰畾鐨刲inting瑙勫垯. | |
| [SASS](http://sass-lang.com/) | C鐢ㄥ彉閲忥紝鍑芥暟绛夌紪璇慍SS鏍峰紡. | [Pluralsight Course](https://www.pluralsight.com/courses/better-css)|
| [PostCSS](https://github.com/postcss/postcss) | 鐢↗S鎻掍欢杞崲鏍峰紡銆� 鐢ㄤ簬autoprefixer CSS |
| [Editor Config](http://editorconfig.org) | 寮哄寲涓€鑷寸殑缂栬緫鍣ㄨ缃紙绌烘牸涓庡埗琛ㄧ绛夛級. | [IDE Plugins](http://editorconfig.org/#download) |
| [npm Scripts](https://docs.npmjs.com/misc/scripts)| 鎵€鏈夎繖浜涢兘闆嗕腑鍦ㄤ竴涓柟渚跨殑鑷姩鍖栨瀯寤轰腑. | [Pluralsight course](https://www.pluralsight.com/courses/npm-build-tool-introduction), [Why not Gulp?](https://medium.com/@housecor/why-i-left-gulp-and-grunt-for-npm-scripts-3d6853dd22b8#.vtaziro8n)  |
| [store](https://github.com/marcuswestin/store.js)| 閽堝鏁翠釜缃戠粶浣跨敤鐨勬墍鏈夌敤渚嬬殑璺ㄦ祻瑙堝櫒瀛樺偍. |  |


---