摘要: homebrew 替换homebrew默认源 替换homebrew core源 "Mac下使用国内镜像安装Homebrew" 使用 安装东西时,提示Xcode outdated 解决方法 打开文件 删除此行代码 Dart环境搭建 安装Dartsdk https://dart.dev/get dart 阅读全文
posted @ 2019-09-01 01:37 hid3onbush 阅读(1156) 评论(0) 推荐(0) 编辑
摘要: webpack3.8.1 = webpack4.39.2 1、error:webpack is not a function fix scripts/start.js const compiler = createCompiler(webpack, config, appName, urls, us 阅读全文
posted @ 2019-08-27 00:12 hid3onbush 阅读(1838) 评论(0) 推荐(0) 编辑
摘要: 装饰器装饰类 修改类了的行为,为它添加了静态属性zs。 装饰器装饰类的方法 装饰类的方法与Object.defineProperty有些许类似。 装饰器的应用 阅读全文
posted @ 2019-05-26 22:43 hid3onbush 阅读(301) 评论(0) 推荐(0) 编辑
摘要: ```js class Example extends React.Component { constructor() { super(); this.state = { val: 0 }; } componentDidMount() { this.setState({val: this.state.val + 1}); con... 阅读全文
posted @ 2019-05-14 18:10 hid3onbush 阅读(612) 评论(0) 推荐(0) 编辑
摘要: ``` import React from "react"; import ReactDOM from "react-dom"; class App extends React.Component { state = { list: [1, 2, 3, 4, 5] }; listChange = index => { const newList = this.sta... 阅读全文
posted @ 2019-05-06 16:31 hid3onbush 阅读(1351) 评论(0) 推荐(0) 编辑
摘要: 自己建web服务器,考虑到安全问题需要用到https。 在此使用nginx的反向代理功能实现https "腾讯云证书安装指引" ssl.conf 配置 重定向需要在 目录下配置html文件 阅读全文
posted @ 2019-04-19 15:17 hid3onbush 阅读(341) 评论(0) 推荐(0) 编辑
摘要: 一.继承 通过原型实现继承 二.继承 借用构造函数实现向父类传递参数 三.继承 组合继承 javascript function Phone(soc) { this.soc = soc; this.color = ['red', 'blue']; } Phone.prototype.getInfo 阅读全文
posted @ 2019-04-17 17:55 hid3onbush 阅读(245) 评论(0) 推荐(0) 编辑
摘要: Object.defineProperty第三个参数descriptor的说明。 数据描述符和存取描述符均具有以下可选键值: 定义了 value 或 writable , 一定不能有 get 或 set, 反之亦然, 否则报错. configurable 当且仅当该属性的 configurable 阅读全文
posted @ 2019-04-15 14:42 hid3onbush 阅读(6185) 评论(0) 推荐(0) 编辑
摘要: ES6 模块化 import命令用于输入其他模块提供的功能;export命令用于规定模块的对外接口。 export 可以有多个,export default 仅有一个 CommonJS 模块化 Node 应用由模块组成,采用 CommonJS 模块规范。 每个文件就是一个模块,有自己的作用域。在一个 阅读全文
posted @ 2019-04-11 11:47 hid3onbush 阅读(653) 评论(0) 推荐(0) 编辑
摘要: 层层传递Props 单向数据流层层传递,繁琐不好管理。 Context 什么是context? context是react提供的组件通信api context有什么用? 解决{组件.js}中多层级组件通信,参数层层传递的麻烦。 context 使用注意事项 1 1 context 提供者(组件)中需 阅读全文
posted @ 2019-04-01 17:17 hid3onbush 阅读(424) 评论(0) 推荐(0) 编辑