View multiple-line-jsx-with-parentheses.tsx
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
const homePageLink = currentPage !== 'home' ? ( | |
<a | |
className="home-page-link" | |
target="_blank" | |
href="#home"> | |
Home | |
</a> | |
) : null; |
View dockerfile
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
FROM python:3.6 | |
ADD . /app | |
WORKDIR /app | |
# | |
RUN pip install --upgrade pip | |
RUN pip install -r requirements.txt | |
# install node and npm for query thumbnail process | |
RUN curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash |
View python_unittest_only_skip_support.py
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
"""Run the unit tests.""" | |
import unittest | |
import sys | |
def iterate_test_cases(test_suite_or_case): | |
"""Iterate through all of the test cases in 'test_suite_or_case'.""" | |
try: | |
suite = iter(test_suite_or_case) | |
except TypeError: |
View multipleCacheMemoize.js
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
/* eslint-disable */ | |
import { createSelectorCreator } from 'reselect'; | |
function execFunc(func, ...args) { | |
return func(...args); | |
} | |
function multipleCacheMemoize(func) { | |
const argsArray = []; | |
const resultArray = []; |
View spotlight.js
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
/* eslint-disable */ | |
import EventEmitter from 'wolfy87-eventemitter'; | |
import isFunction from 'lodash/isFunction'; | |
import isNumber from 'lodash/isNumber'; | |
import isString from 'lodash/isString'; | |
import isPlainObject from 'lodash/isPlainObject'; | |
function eventDelegate(dom, eventName, className, handler) { | |
dom.addEventListener(eventName, function (e) { | |
const target = e.target; |
View git_ftp.sh
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 ftp catchup -u username -p password --remote-root htdoc/daigou --syncroot build --version --verbose ftp://host.example.com:21 |
View app.js
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
// @link https://github.com/reactjs/react-router/blob/v0.13.3/examples/partial-app-loading/app.js | |
var React = require('react'); | |
var Router = require('react-router'); | |
var { Route, RouteHandler, Link } = Router; | |
var AsyncElement = { | |
loadedComponent: null, | |
load: function () { | |
if (this.constructor.loadedComponent) |
View index.html
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> | |
<script src="http://www.parsecdn.com/js/parse-latest.js"></script> | |
<script src="https://adodson.com/hello.js/dist/hello.all.min.js"></script> | |
</head> | |
<body> |
View async-to-q.js
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 fs = require('fs') | |
var Q = require('q') | |
var fs_stat = Q.denodeify(fs.stat) | |
var fs_readdir = Q.denodeify(fs.readdir) | |
var files = [ | |
'./fixtures/file1', | |
'./fixtures/file2', | |
'./fixtures/file3', | |
'./fixtures/file4' |
View getGitInfo.js
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
function getRepoInfo(){ | |
var gitPath = PATH.resolve( process.cwd(), '.git' ); | |
console.log( gitPath ); | |
if( FS.existsSync( gitPath ) ){ | |
var HEAD = FS.readFileSync( PATH.resolve( gitPath, 'HEAD' )).toString(); | |
var CONFIG = FS.readFileSync( PATH.resolve( gitPath, 'config' )).toString(); | |
var result = {}; |
NewerOlder