随笔分类 - angularjs系列教程
将自己读源码的经验分享出来
摘要:injector 有两种类型 ,ProviderInjector 和InstanceInjector .两者get方法执行起来有差异 ProviderInjector 的结构如下: ` { get: function getService(serviceName){ return cacheProv
阅读全文
摘要:angular 会在document上设监听函数 监听DOMContentLoaded事件。 jqLite(window.document).ready(function() { angularInit(window.document, bootstrap); }); 所有当所有脚本执行完毕,构建好
阅读全文
摘要:前言 angular使用起来确实方便,但读通源码能让你使用起来更得心应手,本人抽空将自己读源码时的经验分享给大家。 第一章 模块 angular的模块机制. angular中一个叫modules的对象。该对象存放所有定义的模块。 angular在创建injector的时候会将应用中所有依赖到的定义在
阅读全文

浙公网安备 33010602011771号