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
import { compose, mapProps } from 'recompose' | |
import { withSelectors } from '../tw-app-core' | |
import Features from './Features' | |
import { selectFeatures } from './selectors' | |
export default ( | |
mapToProps: (features: Features) => { [key: string]: boolean } | |
) => | |
compose( |
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
brew install gnupg gnupg2 pinentry-mac | |
gpg2 --gen-key | |
# 1 > 4096 > 0 | |
# Name > Email > Comment (Machine Name?) | |
gpg2 --list-secret-keys --keyid-format LONG | |
# sec 12345/1234567890987654 2016-11-03 >> 1234567890987654 is <id> | |
git config --global user.signingkey <id> | |
gpg2 --armor --export <id> | |
# copy the output to Create new GPG Key in https://github.com/settings/keys |
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
// npm install mailparser | |
// node parse_mail.js | |
var MailParser = require('mailparser').MailParser | |
var fs = require('fs') | |
var dirname = 'sample/' | |
var resultDir = 'result/' | |
if (!fs.existsSync(resultDir)){ | |
fs.mkdirSync(resultDir) | |
} |
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
alias zshconfig="s ~/.zshrc" | |
alias ohmyzsh="s ~/.oh-my-zsh" | |
alias c=cd | |
alias nv="latest-version" | |
alias nh="npm docs" | |
alias nis="npm install --save" | |
alias nid="npm install --save-dev" | |
alias ags="ag --ignore-case --literal" | |
alias nl="npm link --force" | |
alias g=git |
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
var feed = document.querySelectorAll('.alert') | |
var feedType = {} | |
feed.forEach(function(el){ | |
(el.classList).forEach(function(className){ | |
if (feedType[className]) { | |
feedType[className] += 1 | |
} else { | |
feedType[className] = 1 | |
} | |
}) |
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
var inputs = document.querySelectorAll('input[value="5"]') | |
inputs.forEach(function(el){ | |
el.checked = true | |
}) | |
var submit = document.querySelector('input[name="OK"]') | |
submit.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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Document</title> | |
</head> | |
<body> | |
<script src=jquery-2.1.4.min.js></script> | |
<script> | |
var old_id=""; |
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
.product-box { | |
float: left; | |
margin: 20px; | |
width: 400px; | |
background-color: #ddd; | |
box-shadow: 0 3px #cbcbcb; | |
border-radius: 3px; | |
padding: 10px; | |
display: flex; | |
.product-box-picture { |
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
var time = 0, | |
games = document.querySelectorAll(".gameListRow h5"), | |
text; | |
for (var i = 0, len = games.length; i < len; i++) { | |
text = games[i].innerHTML; | |
if(text != "") { | |
time += parseFloat(text.replace(",", "").split(" ")[0]); | |
} | |
} | |
console.log(time); |
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
['id' => 3, | |
'name' => 'Derma Cup Organic Coffee', | |
'slug' => 'derma-cup-organic-coffee', | |
'tel' => '027519968', | |
'open_time' => '10:00:00', | |
'close_time' => '21:00:00', | |
'open_day' => 'ทุกวัน', | |
'min_price' => '0', | |
'max_price' => '100', | |
'building' => 'Sena Fest', |