- sass
cnpm install sass-loader node-sass --save-dev
- pug
cnpm install pug --save-dev
import {DataTables as oDataTables, DataTablesServer as oDataTablesServer} from 'vue-data-tables' | |
import Vue from 'vue' | |
let dataTablesHoc = Component => { | |
return { | |
components: { | |
[Component.name]: Component | |
}, | |
render() { |
cnpm install sass-loader node-sass --save-dev
cnpm install pug --save-dev
class Vue {
constructor(options) {
this.$options = options
this._data = options.data
// proxy所有的data属性
Object.keys(options.data).forEach(key => this._proxy(key))
// 递归的为数据定义get和set
observer(options.data)
// 通过调用render进行依赖收集,从而将_render方到相关data属性的watcher队列中 (1)
"use strict"; | |
/*use in config.xml <hook type="after_platform_add" src="../path/to/cordova-ios-disable-push.js"/>*/ | |
var fs = require("fs"); | |
var path = require("path"); | |
var COMMENT_KEY = /_comment$/; | |
function nonComments(obj) { | |
var newObj = {}; | |
Object.keys(obj).forEach(function(key) { | |
if (!COMMENT_KEY.test(key)) { |
#!/usr/bin/env node | |
var path = require('path'); | |
var fs = require('fs'); | |
var xml2js = require('xml2js'); | |
function xmlFileToJs(filename, cb) { | |
var filepath = path.normalize(path.join(__dirname, filename)); | |
fs.readFile(filepath, 'utf8', function (err, xmlStr) { | |
if (err) throw (err); |
/**
* Create a cached version of a pure function.
*/
export function cached (fn: Function): Function {
const cache = Object.create(null)
return function cachedFn (str: string): any {
const hit = cache[str]
return hit || (cache[str] = fn(str))
}
1 . goto beyond compare
folder
cd "/Applications/Beyond Compare.app/Contents/MacOS/"
2 . rename BCompare
to BCompare.real
mv BCompare BCompare.real