02 2023 档案

摘要:Redux = Reducer + Flux 1. redux 基本使用 1.1 安装 安装 redux npm install redux 安装 redux-thunk(如需支持异步 action) npm install redux-thunk 1.2 使用示例代码 工程目录 src ├─ co 阅读全文
posted @ 2023-02-24 19:21 Better-HTQ 阅读(5) 评论(0) 推荐(0) 编辑
摘要:Initialization setup props and state Mounting componentWillMount render componentDidMount Updation props 发生变化 componentWillReceiveProps // 1.从父组件接收参数 阅读全文
posted @ 2023-02-24 17:34 Better-HTQ 阅读(14) 评论(0) 推荐(0) 编辑
摘要:原始状态 <html> <head> <meta charset="utf-8"> <style> #main { width:300px; height:300px; border:1px solid black; } .a1, .a3 { height: 50px } .a2 { height: 阅读全文
posted @ 2023-02-20 15:54 Better-HTQ 阅读(18) 评论(0) 推荐(0) 编辑
摘要:全局安装脚手架 npm install -g create-react-app 创建项目 npx create-react-app my-app 运行项目 cd my-app npm start 阅读全文
posted @ 2023-02-19 16:09 Better-HTQ 阅读(15) 评论(0) 推荐(0) 编辑
摘要:1. 整洁代码 1.1 要有代码 代码不再是问题;我们应当关注模型和需求。代码很快就能自动产出。这种言论是不正确的。 因为代码呈现了需求的细节,在某些层面上,这些细节无法被忽略或抽象。 即使将来语言的抽象程度继续提升,那么用这种语言开发也同样是代码。同样需要严谨、规范、精确和详细。 1.2 糟糕的代 阅读全文
posted @ 2023-02-08 20:50 Better-HTQ 阅读(94) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示