This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/app/containers/Search.js b/app/containers/Search.js | |
index 6a742f5..d75a738 100644 | |
--- a/app/containers/Search.js | |
+++ b/app/containers/Search.js | |
@@ -7,6 +7,7 @@ import { | |
Dimensions, | |
TouchableOpacity, | |
ListView, | |
+ FlatList, | |
ScrollView |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Bixin Auto Login | |
// @version 0.1 | |
// @author Oaker | |
// @description 币信自动登陆 | |
// @grant none | |
// @match https://bixin.com/auth/login/?next=https%3A//bixin.com/platform/vendor/hashex/ | |
// ==/UserScript== | |
$('#login-acct').click() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Credit to Douglas Crockford for this bind method | |
if (!Function.prototype.bind) { // 如果不存在 bind 方法 | |
Function.prototype.bind = function (oThis) { | |
if (typeof this !== "function") { // bind 方法的调用对象只能是函数,如果不是则抛出异常 | |
// closest thing possible to the ECMAScript 5 internal IsCallable function | |
throw new TypeError ("Function.prototype.bind - what is trying to be bound is not callable"); | |
} | |
var aArgs = Array.prototype.slice.call (arguments, 1), // 浅复制 bind 的参数,从第 2 个开始到结束 http://stackoverflow.com/a/26618338/5657916 | |
fToBind = this, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
blockquote { | |
font-style: normal; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sub BatchExportRowsToCSV() | |
Dim Filename, Pathname As String | |
Dim wb As Workbook | |
Pathname = ActiveWorkbook.Path & "\source\" | |
Filename = Dir(Pathname & "*.xlsm") | |
Do While Filename <> "" | |
Set wb = Workbooks.Open(Pathname & Filename) | |
ExcelRowsToCSV wb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git init --bare $HOME/.dotfiles | |
alias dotfiles='/usr/bin/git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME' | |
dotfiles config --local status.showUntrackedFiles no | |
echo "alias dotfiles='/usr/bin/git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME'" >> $HOME/.zshrc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 快速创建成员为0-9的数组,等价的两种方式 | |
// let arr = [] | |
// arr.length = 10 | |
let arr = new Array(10) // 参数为个位数,表示长度,否则表示成员 | |
//let arr = new Array(0, 1, 2) | |
for (let i=0; i<arr.length; i++) { | |
arr[i] = i |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// JS不能实现成员不可变数组 | |
const a = 1 | |
const arr = [a] | |
console.log(arr) | |
arr[0] = 2 // 赋值时替换了常量a | |
console.log(arr) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
AZHU.storage = { | |
save : function(key, jsonData, expirationMin){ | |
if (!Modernizr.localstorage){return false;} | |
var expirationMS = expirationMin * 60 * 1000; | |
var record = {value: JSON.stringify(jsonData), timestamp: new Date().getTime() + expirationMS} | |
localStorage.setItem(key, JSON.stringify(record)); | |
return jsonData; | |
}, | |
load : function(key){ | |
if (!Modernizr.localstorage){return false;} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
css reset | |
*/ | |
html{ | |
-webkit-tap-highlight-color: rgba(0,0,0,0);/*去掉触摸遮盖层*/ | |
-webkit-user-modify: read-write-plaintext-only; | |
-webkit-user-select: none;/*禁止用户选择文字*/ | |
} |