XUN'S BLOG


  • Home

  • Tags

  • Categories

  • Archives

  • Schedule

  • guestbook

  • Search

egg-mysql 实战

Posted on 2020-05-29 |
egg-mysql安装1npm i egg-mysql --save 配置/config/plugin.js 12345678910111213'use strict';/** @type Egg.EggPlugin */module.exports = { // had enabled ...
Read more »

原型链,实例原型与实例对象

Posted on 2020-04-04 | In JavaScript |
原型链,实例原型与实例对象构造函数与实例原型什么是构造函数?构造函数与普通函数的区别: 1. 构造函数通常以大写字母开头命名,普通函数则常采用驼峰式命名或纯小写;2. 调用方式不同:构造函数常用new关键字调用,普通函数直接调用函数名。3. 意义不同:构造函数代表生成一个类,和关联一个原型实例,其类 ...
Read more »

React合成事件与原生事件的机制冲突

Posted on 2020-03-25 | In react |
React合成事件与原生事件的机制冲突场景,当在某组件/dom节点绑定事件时,如果此时document也绑定了事件,则会产生冒泡,触发document事件。 阻止冒泡:原生场景1234567891011121314151617181920<body> <div id="div ...
Read more »

React源码学习(五)React-forwardref

Posted on 2020-03-03 |
forwardRef是用来解决HOC组件传递ref的问题的,所谓HOC就是Higher Order Component,比如使用redux的时候,我们用connect来给组件绑定需要的state,这其中其实就是给我们的组件在外部包了一层组件,然后通过…props的方式把外部的props传入到实际组 ...
Read more »

React源码学习(四)React-ref

Posted on 2020-03-03 |
react-ref通过获取实例,操作其属性及方法。React暴露api,React.createRef();该源码位于 ReactCreateRef.js 123456789101112import type {RefObject} from 'shared/ReactTypes ...
Read more »

React源码学习(三)ReactComponent

Posted on 2020-03-03 |
组件是react中的一个重要特性。 React.Component源码Component和Pure Component Component12345678910111213/** * Base class helpers for the updating state of a component. ...
Read more »

React源码学习(二)ReactElement

Posted on 2020-03-03 |
ReactElement在(一)中实践发现,jsx转换成React.createElement代码,这个API的作用是生成虚拟dom,转换成html标签。 123456789101112131415161718192021222324252627282930313233343536373839404 ...
Read more »

React源码学习(一)JSX到JavaScript的转换

Posted on 2020-03-03 |
JSX到JavaScript的转换babeljs 的作用 Babel 是一个 JavaScript 编译器Babel 是一个工具链,主要用于将 ECMAScript 2015+ 版本的代码转换为向后兼容的 JavaScript 语法,以便能够运行在当前和旧版本的浏览器或其他环境中。 JSX 的作用 ...
Read more »

JavaScript深拷贝

Posted on 2020-01-12 | In JavaScript |
JavaScript深拷贝递归实现1234567891011121314151617181920212223var deepclone=function (target) { if(typeof target=='object'){ if(target==nu ...
Read more »

http与https协议

Posted on 2020-01-08 | In 面经 |
HTTPhttp是超文本传输协议,是一种无状态的协议。http是基于tcp的,因为tcp是可靠的数据传输。一次完整的http传输包含三次握手与四次挥手,三次握手表示建立连接,四次挥手表示断开连接。 三次握手 客户端发送SYN,自身状态为SYN-SENT,等待服务器端确认,表示客户端可以向服务器端发送 ...
Read more »
12…11>
GoldMiner Xun

GoldMiner Xun

104 posts
17 categories
56 tags
GitHub E-Mail Twitter weibo
Links
  • 我的崽
  • 哈理工超级课程表网页版
0%
© 2020 GoldMiner Xun
Powered by Hexo
|
Theme — NexT.Pisces v5.1.4
visitors times sitevisits times