React Starter Kit | Create React App | Custom Project Template |
---|
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
#!/bin/sh | |
# ngrok's web interface is HTML, but configuration is bootstrapped as a JSON | |
# string. We can hack out the forwarded hostname by extracting the next | |
# `*.ngrok.io` string from the JSON | |
# | |
# Brittle as all get out--YMMV. If you're still reading, usage is: | |
# | |
# $ ./ngrok_hostname.sh <proto> <addr> | |
# |
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
app.configure(function() { | |
//. . . | |
app.use(express.bodyParser()); | |
app.use(function(req, res, next) { | |
var data = ''; | |
req.setEncoding('utf8'); | |
req.on('data', function(chunk) { | |
data += chunk; | |
}); | |
req.on('end', function() { |
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
/* eslint-disable no-param-reassign, max-len */ | |
const findItinerary = (tickets, debug) => { | |
const graph = tickets.reduce((s, v) => { | |
const [key, value] = v; | |
if (!s[key]) { | |
s[key] = []; | |
} | |
s[key].push(value); | |
return s; | |
}, {}); |
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
#!/bin/bash | |
# | |
# Generates client and server certificates used to enable HTTPS | |
# remote authentication to a Docker daemon. | |
# | |
# See http://docs.docker.com/articles/https/ | |
# | |
# To start the Docker Daemon: | |
# | |
# sudo docker -d \ |
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
'use strict'; | |
/* | |
arr = [1, 2, 3] | |
for each element in arr, create subArr | |
for i = 1 => subArr = [2, 3] | |
for i = 2 => subArr = [1, 3] | |
for each subArr, get permutations | |
(ex: [2, 3] => [ [2, 3], [3, 2] ]) |
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
(function(){ | |
var newscript = document.createElement('script'); | |
newscript.type = 'text/javascript'; | |
newscript.async = true; | |
newscript.src = 'https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js'; | |
(document.getElementsByTagName('head')[0]||document.getElementsByTagName('body')[0]).appendChild(newscript); | |
})(); |
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
window.redirectTo = function(){ | |
// android redirect | |
if (window.navigator.userAgent.match(/Android/)){ | |
setTimeout(function() { | |
if (!document.webkitHidden){ | |
window.location = 'https://play.google.com/store/apps/details?id=com.linkwish.onepiece'; | |
} | |
}, 1000); | |
window.location = 'fb1393011827627092://'; |
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
require.config({ | |
paths: { | |
jquery: '../bower_components/jquery/jquery', | |
bootstrapAffix: '../bower_components/sass-bootstrap/js/affix', | |
bootstrapAlert: '../bower_components/sass-bootstrap/js/alert', | |
bootstrapButton: '../bower_components/sass-bootstrap/js/button', | |
bootstrapCarousel: '../bower_components/sass-bootstrap/js/carousel', | |
bootstrapCollapse: '../bower_components/sass-bootstrap/js/collapse', | |
bootstrapDropdown: '../bower_components/sass-bootstrap/js/dropdown', | |
bootstrapPopover: '../bower_components/sass-bootstrap/js/popover', |
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
{ | |
"name": "", | |
"version": "0.0.0", | |
"dependencies": { | |
"sass-bootstrap": "~3.0.0", | |
"requirejs": "~2.1.8", | |
"jquery": "~1.10.2", | |
"angular": "~1.2.6", | |
"angular-route": "~1.2.6", | |
"requirejs-text": "~2.0.10", |