Install jquery
& jquery-ui
:
$ npm install --save jquery jquery-ui
Install deamdify
:
$ npm install --save-dev deamdify
/* | |
0) start node app: | |
$ node app.js | |
1) start stream listening: | |
browse to http://localhost:3000/ | |
2) stop stream listening: | |
browse to http://localhost:3000/stop | |
*/ |
source ~/.bashrc |
Install jquery
& jquery-ui
:
$ npm install --save jquery jquery-ui
Install deamdify
:
$ npm install --save-dev deamdify
const crypto = require('crypto'); | |
const hashjs = require('hash.js'); | |
const baseCodec = require('base-x'); | |
const codec = baseCodec("rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz"); // for ripple | |
// npm install --save ripple-keypairs ripple-binary-codec ripple-hashes | |
const Keypairs = require('ripple-keypairs'); | |
// const Binary = require('ripple-binary-codec'); | |
const { | |
computeBinaryTransactionHash | |
} = require('ripple-hashes'); |
const fs = require("fs"); | |
const readline = require('readline'); | |
const iconv = require('iconv-lite'); | |
const readStream = fs.createReadStream("./shift_jis.txt", { encoding: "binary" }); | |
const rl = readline.createInterface(readStream, {}); | |
rl.on('line', function(line) { | |
// Shift_JIS => unicode: | |
console.log("line:", iconv.decode(new Buffer(line, "binary"), "Shift_JIS")); |
npm install vue@csp --save |
-- Use `ORDER BY FIELDS(<column>, <value>, <value>, ...)` | |
SELECT * FROM tbl | |
WHERE id IN (3, 1, 2) | |
ORDER BY FIELD(id, 1, 2, 3); | |
-- Returns records ordered by id ASC (order is id:1, id:2, id:3) |
const cluster = require('cluster'); | |
const numCPUs = require('os').cpus().length; | |
var tasks = [ | |
"Dusting", | |
"Sweeping", | |
"Vacuuming", | |
"Washing dishes", | |
"Feeding pets", | |
"Doing laundry", |
#!/usr/bin/env node | |
/** | |
* Ripple CLI tool | |
* | |
* The MIT License (MIT) | |
* Copyright (c) 2017 akirattii <tanaka.akira.2006@gmail.com> (http://mint.pepper.jp) | |
*/ | |
/** | |
# Usage & example: |
/** | |
* reCAPTCHA checking middleware | |
* | |
* Usage: | |
* ``` | |
* var checkReCAPTCHA = require("../middleware/CheckReCAPTCHA.js").checkReCAPTCHA; | |
* router.post('/hoge', | |
* checkReCAPTCHA(), | |
* function(req, res, next) { | |
* // |