Coder Social home page Coder Social logo

react-catemall's Introduction

react-cateMall

react技术栈

  • react react-router4 redux react-redux

初始化package.json

$ yarn init -y

webpack

$ yarn add webpack webpack-dev-server --dev

babel

$ yarn add babel-core babel-loader babel-preset-es2015 babel-preset-stage-0 babel-preset-react css-loader style-loader less less-loader html-webpack-plugin --dev

react

$ yarn add react redux react-redux react-router-dom react-dom

fetch

$ yarn add es6-promise whatwg-fetch --dev

express

$ yarn add express

swipe插件

$ yarn add swipe-js-iso react-swipe

scripts

package.json +

"scripts":{
    "start","webpack-dev-server --port 5000 --open --progress --colors",
    "build","webpack -p"
}

目录结构

  • components 组件 木偶组件

  • containers 页面组件,或者自己的subpage目录下

    • Home
      • subpage 智能组件
      • index.js
  • index.js 用来控制显示哪一个页面

    //redux

  • store 只有一个

  • actions 用户发布动作

  • reducers 定义规则的

  • action-types action的名字

extract-text-webpack-plugin

  • 抽取css的以link标签引入

postcss-loader

  • 添加前缀

配置多入口 verdor

  • 抽离第三方库

react-catemall's People

Contributors

xuxiaowen avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.