随笔分类 -  react

摘要:Redux 安装指令是: > yarn add redux react-redux Redux 中的核心是: store 是应用的状态管理中心,保存着是应用的状态(state),当收到状态的更新时,会触发视觉组件进行更新。 container 是视觉组件的容器,负责把传入的状态变量渲染成视觉组件,在 阅读全文
posted @ 2020-07-18 20:51 柚子小哥哥 阅读(3742) 评论(0) 推荐(0)
摘要:父传子: 父组件: 1 import React from 'react'; 2 import './App.css'; 3 //引入子组件 4 import Nav from "./components/Nav"; 5 export default class App extends React. 阅读全文
posted @ 2020-07-13 23:19 柚子小哥哥 阅读(190) 评论(0) 推荐(0)
摘要:< react router> (路由): 思维导图: Atrial 文件夹下的index.js 文件内容: 1 import React, { Component } from 'react' 2 import{ 3 Link, 4 }from 'react-router-dom' 5 expor 阅读全文
posted @ 2020-02-14 19:51 柚子小哥哥 阅读(157) 评论(0) 推荐(0)
摘要:<react> 组件的详细介绍: 思维导图: 代码介绍: TodoList:(组件) 1 import React, { Component } from 'react' 2 import Style from './style.css' 3 4 export default class index 阅读全文
posted @ 2020-02-12 13:58 柚子小哥哥 阅读(336) 评论(0) 推荐(0)
摘要:< react TodoList: > 组件: 1 //引入React ; 2 import React from 'react'; 3 //组件 4 class TodoList extends React.Component{ 5 constructor(props){ 6 super(prop 阅读全文
posted @ 2020-02-07 21:20 柚子小哥哥 阅读(279) 评论(0) 推荐(0)
摘要:Reactjs code snippets (vs code 编辑器里面的一个插件 支持 react 得简写) rcc 和 rfc 可以快速生成react代码 下面网址是个react文档: https://materialui-ch.gitbooks.io/material-ui_doc_chine 阅读全文
posted @ 2020-01-17 22:03 柚子小哥哥 阅读(452) 评论(0) 推荐(0)
摘要:react 使用方法: 第一步: 初始化react 项目 (1)安装node npm (2)npm install --global create-react-app (3)create-react-app my-app (4)cd ./my-app npm start (运行) 第二步: reac 阅读全文
posted @ 2019-12-28 20:36 柚子小哥哥 阅读(637) 评论(0) 推荐(0)