组件 自定义组件 全局注册: var question={name:'MR Liu'} Vue.component('my-header',{ template:'<p>hello world{{name}}</p> ', data:function(){//data必须是函数 且一般只能返回一个对 ...
分类:
Web程序 时间:
2017-09-19 00:15:06
阅读次数:
230
函数是可以实现一些特定功能的小方法或小程序定义函数function的方法:def function_name(arg1,arg2[,...]): statement [return value]注意事项:1.def开头,代表定义函数,def和函数名中间要敲一个空格;2.返回值不是必须的,如果没有re ...
分类:
编程语言 时间:
2017-09-18 22:39:20
阅读次数:
427
这道题为简单题 题目: Given an array of integers, find if the array contains any duplicates. Your function should return true if any value appears at least twic ...
分类:
其他好文 时间:
2017-09-18 19:48:04
阅读次数:
112
实例练习 左侧菜单 <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>left_menu</title> <style> .menu{ height: 500px; width: 20%; background ...
分类:
Web程序 时间:
2017-09-18 19:43:23
阅读次数:
292
//统计 public static function is_set_or_plus(&$val,$num){ if(!isset($val)) { $val= 0; } $val+=$num; } //赋值 public static functio... ...
分类:
其他好文 时间:
2017-09-18 17:31:27
阅读次数:
147
function a(arg) { arguments.callee['fn' + arg] = !arguments.callee['fn' + arg]; console.log(arguments.callee['fn' + arg]); } ...
分类:
其他好文 时间:
2017-09-18 17:27:02
阅读次数:
159
拼音码 拼音码 select comm.fun_spellcode('数据库') from dual 结果 : SJK 函数 函数 ...
分类:
数据库 时间:
2017-09-18 15:03:23
阅读次数:
343
1 . 请解释事件代理 (event delegation) 当需要对很多元素添加事件的时,可以通过将事件添加到它们的父节点通过委托来触发处理函数。其中利用到了浏览器的事件冒泡机制。 var delegate = function(client, clientMethod) { return fun ...
分类:
Web程序 时间:
2017-09-18 12:24:27
阅读次数:
328
function setTips(that,title){ var pos = getPos(that); var maxWidth = 0 ; var minWidth = 0 ; var sreenX = window.innerWidth; var sreenY = window.innerH ...
分类:
Web程序 时间:
2017-09-18 12:18:24
阅读次数:
340
Given a binary tree, write a function to get the maximum width of the given tree. The width of a tree is the maximum width among all levels. The binar ...
分类:
其他好文 时间:
2017-09-18 01:18:26
阅读次数:
240