- 博客(233)
- 收藏
- 关注
原创 Render Prop
mixins、hoc、render prop比较 https://segmentfault.com/a/1190000013457428
2018-07-17 09:13:17 168
原创 稀疏数组&密集数组
需要注意Array很多方法在遍历时跳过了稀疏数组元素,比如filter、map https://blog.csdn.net/aitangyong/article/details/40191305/ https://blog.csdn.net/wangji5850/article/details/51135948...
2018-07-13 10:02:54 279
原创 storageChange
值得特别注意的是,storage事件不在导致数据变化的当前页面触发。如果浏览器同时打开一个域名下面的多个页面,当其中一个页面改变sessionStorage或localStorage的数据时,其他所有页面的storage事件会被触发,而原始页面并不触发storage事件。可以通过这种机制,实现多个窗口之间的通信。所有浏览器之中,只有IE浏览器除外,它会在所有页面触发storage事...
2018-06-28 17:31:12 671
原创 页面关闭发送数据 sendBeacon
navigator.sendBeacon http://www.yunnanhaoli.com/web/javascript/510.html
2018-06-27 16:24:22 868
原创 Event 接口
event.eventPhase event.path || event.composedPath() || polyfill http://javascript.ruanyifeng.com/dom/event.html
2018-06-27 10:20:17 336
原创 currentScript
如何获取当前js文档的地址 https://blog.csdn.net/cuixiping/article/details/45917149
2018-06-11 13:13:35 117
原创 RuleSet之compiler/issuer
上节说明了参数rule.resource/rule.resourceQuery 配置值可以是string、regex、funciton、array组合, 关键在于通过RuleSet.normalizeCondition处理实现 比较完整的格式如下:module: { rules: [{ resource: { test: /\.js$/,...
2018-06-07 10:00:21 255
原创 RuleSet之resource/resourceQuery
RuleSet解析webpack.config.js设定的一系列配置约束(module.rules部分), 结合import(resourcePath)/require(resourcePath)引入的资源, 计算resourcePath和配置规则的匹配结果 直白的说,可以认为这个过程是筛选使用哪些loader去加载处理资源的过程 webpack源码RuleSet看到c...
2018-06-07 09:16:55 1609
原创 入口之webpackJsonpCallback
每个chunk的入口函数,基本上做了三件事,比如针对app.jswebpackJsonpCallback([0,1], { 2: function(){}, 3:function(){}}, [2]); 1.chunk1有可能依赖chunk0,要先执行chunk0,也有可能chunk0已经执行过了,所以需要判断 2.将module = 2/3 的定义保存在modu...
2018-06-06 11:07:47 7736
原创 @types typings
http://www.bubuko.com/infodetail-1876184.html https://segmentfault.com/a/1190000007560996 https://segmentfault.com/a/1190000011877674
2018-06-06 08:42:13 357
原创 源码解读
这个系列不错https://www.cnblogs.com/QH-Jimmy/p/8034891.html https://mp.weixin.qq.com/s?__biz=MzI3NTM1MjExMg==&mid=2247484647&idx=1&sn=0ffc79ae9c1ca56d972bcb13bedc848e&scene=21#wec...
2018-06-05 11:15:39 134
原创 webpack优化
https://jeffjade.com/2017/08/12/125-webpack-package-optimization-for-speed/ https://github.com/webpack-china/awesome-webpack-cn/issues/1
2018-06-04 09:02:27 89
原创 compiler.apply.apply(compiler, optoins.plugins)
webpack.js文件有一句代码特别拗口compiler.apply.apply(compiler, options.plugins);compiler = new Compiler(); compiler.context = options.context; compiler.options = options; new NodeEnvironmentPlugin...
2018-06-01 14:57:43 402
原创 入口之__webpack_require__
此处module,exports并不是commonJS、CMD、AMD规范的module,exports而是webpack自定义的对象 module和chunk是不同的设定,chunk可以理解为一个个的js文件,module理解为chunk文件的组成部分,根据功能划分的代码块/******/ // The require function/******/ fun...
2018-06-01 11:32:06 8253
原创 入口之__webpack_require__.e
这个方法适用于通过require.ensure或者import()懒加载的模块chunk分init chunk,entry chunk,normal chunk init chunk指代不包含runtime代码的chunk,一般是通过webpack的entry配置的入口 entry chunk指代包含runtime代码的chunk,一般通过commonchunkpl...
2018-06-01 11:09:33 1504
原创 file-loader & url-loader
limit配置:https://blog.csdn.net/qq_38652603/article/details/73835153 通过css文件配置:.bg{background-image: url('test.jpg');} 通过file-loader配置use: [{ loader: 'u...
2018-05-29 09:34:58 143
原创 server side render
https://juejin.im/post/5a9ca40b6fb9a028b77a4aac https://ssr.vuejs.org/guide/data.html#store-code-splitting
2018-05-28 13:39:39 121
原创 prerender-spa-plugin
预渲染 http://52laoshiji.com/article/848 https://segmentfault.com/a/1190000010613010
2018-05-28 13:39:07 120
原创 imports-loader exports-loader expose-loader
imports-loader就是根据预设规则,在require('x')时,将bundle的第三方依赖注入,防止报错Query valueEqualsangular var angular = require("angular");$=jqueryvar $ = require("jquery");define=>falsevar ...
2018-05-28 08:45:14 361
原创 babel-preset-env
https://segmentfault.com/a/1190000010468759 https://excaliburhan.com/post/babel-preset-and-plugins.html http://2ality.com/2017/02/babel-preset-env.html
2018-05-22 09:43:19 280
原创 bundle-loader & promise-loader
只是对require.ensure进行了封装而已 promise-loader返回了promise实例 lazy比较关键,建议看源码一下
2018-05-22 09:35:27 211
原创 require.ensure & import
注意点:1.重命名2.babel-plugin-syntax-dynamic-import3.Promise http://doc.okbase.net/stef/archive/260193.html https://webpack.js.org/guides/code-splitting/
2018-05-22 09:24:56 248
原创 fullpage类似
https://github.com/alvarotrigo/fullPage.js https://github.com/alvarotrigo/pagePiling.js https://github.com/luruke/barba.js https://github.com/hakimel/reveal.js https://github.com/...
2018-05-22 09:12:18 359
原创 ArrayBuffer
https://www.cnblogs.com/copperhaze/p/6149041.html https://blog.csdn.net/jack__cj/article/details/53026278
2018-05-22 09:12:11 238
原创 浏览器滚动时动画效果
https://github.com/matthieua/WOW http://johnpolacek.github.io/scrollorama/
2018-05-21 13:59:59 531
原创 JS Bridge
https://github.com/lzyzsd/JsBridge https://github.com/marcuswestin/WebViewJavascriptBridge https://www.cnblogs.com/iOS-eflying/p/7143552.html https://blog.csdn.net/carson_ho/article/d...
2018-05-21 13:59:43 117
原创 动画相关include svg vml
https://github.com/visionmedia/move.js https://github.com/maxwellito/vivus https://github.com/aterrien/jQuery-Knob
2018-05-21 13:48:01 121
原创 图表报表
https://github.com/gwatts/jquery.sparkline https://github.com/chartjs/Chart.js
2018-04-28 11:35:53 109
原创 冒泡VS捕获 顺序
https://www.cnblogs.com/alvinwei1024/p/4739344.html 首先捕获从document -> target然后冒泡从target -> document 同一个元素element上注册冒泡与捕获监听,谁先注册,谁先执行...
2018-03-21 09:31:11 188
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人