This file contains hidden or 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
// Yellow - Decorator for method | |
function isFruit(name){ | |
return ['banana', 'apple'].indexOf(name) !== -1; | |
} | |
function not(fn){ | |
return function(){ | |
return !fn.apply(null, arguments); | |
}; | |
} |
This file contains hidden or 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
// Yellow - Decorator for method | |
function isFruit(name){ | |
return ['banana', 'apple'].indexOf(name) !== -1; | |
} | |
function not(fn){ | |
return function(){ | |
return !fn.apply(null, arguments); | |
}; | |
} |
This file contains hidden or 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
// Yellow - Decorator for method | |
function isFruit(name){ | |
return ['banana', 'apple'].indexOf(name) !== -1; | |
} | |
function not(fn){ | |
return function(){ | |
return !fn.apply(null, arguments); | |
}; | |
} |
This file contains hidden or 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
// Yellow - Decorator for method | |
function isFruit(name){ | |
return ['banana', 'apple'].indexOf(name) !== -1; | |
} | |
function not(fn){ | |
return function(){ | |
return !fn.apply(null, arguments); | |
}; | |
} |
This file contains hidden or 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
// Yellow - Decorator for method | |
function isFruit(name){ | |
return ['banana', 'apple'].indexOf(name) !== -1; | |
} | |
function not(fn){ | |
return function(){ | |
return !fn.apply(null, arguments); | |
}; | |
} |
This file contains hidden or 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
// Yellow - Decorator for method | |
function isFruit(name){ | |
return ['banana', 'apple'].indexOf(name) !== -1; | |
} | |
function not(fn){ | |
return function(){ | |
return !fn.apply(null, arguments); | |
}; | |
} |
This file contains hidden or 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
<link rel="import" href="../core-scaffold/core-scaffold.html"> | |
<link rel="import" href="../core-header-panel/core-header-panel.html"> | |
<link rel="import" href="../core-menu/core-menu.html"> | |
<link rel="import" href="../core-item/core-item.html"> | |
<link rel="import" href="../core-icon-button/core-icon-button.html"> | |
<link rel="import" href="../core-toolbar/core-toolbar.html"> | |
<link rel="import" href="../core-field/core-field.html"> | |
<link rel="import" href="../core-icon/core-icon.html"> | |
<link rel="import" href="../core-input/core-input.html"> | |
<link rel="import" href="../core-icons/core-icons.html"> |
This file contains hidden or 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
# 1 | |
# register an user at npmjs.org | |
# 2 | |
npm adduser | |
# 3 | |
cd /path/to/your/package |
This file contains hidden or 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
Node.JS | |
This is ApacheBench, Version 2.3 <$Revision: 655654 $> | |
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ | |
Licensed to The Apache Software Foundation, http://www.apache.org/ | |
Benchmarking 127.0.0.1 (be patient) | |
Completed 1000 requests | |
Completed 2000 requests | |
Completed 3000 requests | |
Completed 4000 requests |
This file contains hidden or 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
echo "\n\n# Benchmarking Golang" | |
go build server.go | |
./server & | |
PID=$! | |
sleep 2 | |
ab -c 100 -n 10000 http://127.0.0.1:8000/ | |
kill $PID | |
echo "\n\n# Benchmarking Node.js" | |
node server.js & |