habc0807 / react-miniproject

使用react技术栈一个项目

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

This project was bootstrapped with Create React App.

Available Scripts

In the project directory, you can run:

npm start

Runs the app in the development mode.
Open http://localhost:3000 to view it in the browser.

The page will reload if you make edits.
You will also see any lint errors in the console.

npm test

Launches the test runner in the interactive watch mode.
See the section about running tests for more information.

npm run build

Builds the app for production to the build folder.
It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.
Your app is ready to be deployed!

See the section about deployment for more information.

npm run eject

Note: this is a one-way operation. Once you eject, you can’t go back!

If you aren’t satisfied with the build tool and configuration choices, you can eject at any time. This command will remove the single build dependency from your project.

Instead, it will copy all the configuration files and the transitive dependencies (Webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except eject will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own.

You don’t have to ever use eject. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it.

Learn More

You can learn more in the Create React App documentation.

To learn React, check out the React documentation.

Code Splitting

This section has moved here: https://facebook.github.io/create-react-app/docs/code-splitting

Analyzing the Bundle Size

This section has moved here: https://facebook.github.io/create-react-app/docs/analyzing-the-bundle-size

Making a Progressive Web App

This section has moved here: https://facebook.github.io/create-react-app/docs/making-a-progressive-web-app

Advanced Configuration

This section has moved here: https://facebook.github.io/create-react-app/docs/advanced-configuration

Deployment

This section has moved here: https://facebook.github.io/create-react-app/docs/deployment

npm run build fails to minify

This section has moved here: https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify

  1. immutable 库 immutable对象 用来解决什么问题的,如果没有这个库,自己怎么解决这个问题 防止在业务里直接修改 数据类型, im mutable 不可改变 不可更改,但是可以改变其深层的数据类型?为什么?这样要它何用。

在使用的时候就需要使用 get, 更新数据的时候使用set更新,它不会直接更改state, immutable对象的set方法,会结合之前immutable对象的值和设置的值,返回一个全新的对象

  1. redux-immutable 模块 为什么要有这个模块,解决什么问题,有点和缺点
const mapStateToProps = (state) => ({
    focused: state.header.get('focused')
});

state是一个js对象,state.header是一个immutable对象,我们系统统一成immutable对象。我们希望state也成为一个immutable

  1. combineReducers 在redux和redux-immutable都有 有什么区别,为什么从新封装了,却不更改名字?

  2. react-router 和 react-router-dom的区别是什么 react-router做了什么事,实现原理 react-router-dom 为什么有这个模块,用来解决什么问题的,其实现原理是什么?

Route 与 Router的区别

About

使用react技术栈一个项目


Languages

Language:JavaScript 80.9%Language:CSS 11.6%Language:HTML 7.6%