vue.js 源代码学习笔记 ----- instance index
import { initMixin } from './init'
import { stateMixin } from './state'
import { renderMixin } from './render'
import { eventsMixin } from './events'
import { lifecycleMixin } from './lifecycle'
import { warn } from '../util/index'
function Vue (options) {
if (process.env.NODE_ENV !== 'production' &&
!(this instanceof Vue)) {
//提示需要 new 实例化
warn('Vue is a constructor and should be called with the `new` keyword')
}
this._init(options)
}
//扩展vue的原型方法
initMixin(Vue)
stateMixin(Vue)
eventsMixin(Vue)
lifecycleMixin(Vue)
renderMixin(Vue)
export default Vue
vue.js 源代码学习笔记 ----- instance index的更多相关文章
- vue.js 源代码学习笔记 ----- instance render
/* @flow */ import { warn, nextTick, toNumber, _toString, looseEqual, emptyObject, handleError, loos ...
- vue.js 源代码学习笔记 ----- instance state
/* @flow */ import Dep from '../observer/dep' import Watcher from '../observer/watcher' import { set ...
- vue.js 源代码学习笔记 ----- instance event
/* @flow */ import { updateListeners } from '../vdom/helpers/index' import { toArray, tip, hyphenate ...
- vue.js 源代码学习笔记 ----- instance proxy
/* not type checking this file because flow doesn't play well with Proxy */ import config from 'core ...
- vue.js 源代码学习笔记 ----- instance init
/* @flow */ import config from '../config' import { initProxy } from './proxy' import { initState } ...
- vue.js 源代码学习笔记 ----- instance inject
/* @flow */ import { hasSymbol } from 'core/util/env' import { warn } from '../util/index' import { ...
- vue.js 源代码学习笔记 ----- 工具方法 option
/* @flow */ import Vue from '../instance/index' import config from '../config' import { warn } from ...
- vue.js 源代码学习笔记 ----- html-parse.js
/** * Not type-checking this file because it's mostly vendor code. */ /*! * HTML Parser By John Resi ...
- vue.js 源代码学习笔记 ----- core lifecycle
/* @flow */ import config from '../config' import Watcher from '../observer/watcher' import { mark, ...
随机推荐
- C#基础--多线程
一.微软早期操作系统中的问题 在早期的操作系统中,应用程序都是在同一个地址空间中运行的,每个程序的数据其它程序都是可见的,并且因为早期CPU是单内核 的所以所有的执行都是线性的.这就引出两个问题: 第 ...
- JS类、对象、方法、prototype、_proto_
案例代码: function People(name) { //对象属性 this.name = name; //对象方法 this.Introduce = function() { alert(&q ...
- python error: curl: (1) Protocol "'https" not supported or disabled in libcurl
python 调用curl访问一个网页时,出现error: curl: (1) Protocol "'https" not supported or disabled in lib ...
- Android studio通过连接蓝叠模拟器大幅提高速度!
因为我的电脑是X200,集成显卡,不支持Opengl 2.0,很多安卓模拟器都不能用(夜神.海马玩,mumu等)最后发现蓝叠. 首先WIN+R,CMD,输入ADB,如果没有命令信息,说明我们需要在PA ...
- 都能看懂的嵌入式linux/android alsa_aplay alsa_amixer命令行用法
前几天在嵌入式linux上用到alsa command,网上查的资料多不给力,只有动手一点点查,终于可以用了,将这个使用方法告诉大家,以免大家少走弯路. 0.先查看系统支持哪几个alsa cmd: l ...
- 01_MySQL DQL_基础查询
DQL,Data Query Language,数据查询 # 基础查询/*语法:select 查询列表 from 表名: 特点:1.查询列表可以是:表中的字段,常量值.表达式.函数,也可以是多个组合2 ...
- select * from table_name where 1=1的
我们先来看看这个语句的结果:select * from table where 1=1,其中where 1=1,由于1=1永远是成立的,返回TRUE,条件为真:所以,这条语句,就相当于select * ...
- ThinkPHP开发笔记-模型
1.模型定义.在ThinkPHP中,可以无需进行任何模型定义.只有在需要封装单独的业务逻辑的时候,模型类才是必须被定义的,因此ThinkPHP在模型上有很多的灵活和方便性,让你无需因为表太多而烦恼. ...
- Codeforces Round #360 (Div. 2) D. Remainders Game
D. Remainders Game time limit per test 1 second memory limit per test 256 megabytes input standard i ...
- 实用SQL语句
sp_depends t_im_flow 获取到与这个表有关系的存储过程.触发器.函数.视图等.