- 博客(2)
- 资源 (1)
- 收藏
- 关注
翻译 对exports 和 module.exports的理解
exports指向module.exports,不可重新赋值为新对象,只能添加属性及内部方法 exports.test = function(){ console.log(‘122’) }; exports.name = ‘xss’; 和 module.exports = { name: ‘xss’, test: function(){ console.log(‘122’) } }; 效果...
2019-04-19 12:25:46 249
翻译 对事件机制的理解
捕获阶段 –> 目标阶段 -> 冒泡阶段 –> 默认行为 非IE: IE: 阻止事件默认行为 非IE: event.preventDefault() IE: event.returnValue=false; 阻止冒泡 非IE: event.stopPropagation () IE: event.cancelBubble=true; 冒泡阶段注册事件 ...
2019-04-19 12:23:46 227
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人