code stringlengths 2 1.05M |
|---|
Lizard.Models.CollageItem = Backbone.AssociatedModel.extend({
defaults: {
graph_index: 0,
timeseries: []
}
});
|
import React from 'react';
import { ListItem, Radio, Left, Right, Text } from 'native-base';
// Radio button list item with title and note.
const RadioWithNote = ({ title, note, selected, onPress }) =>
<ListItem selected={selected} onPress={onPress} >
<Left>
<Radio selected={selected} onPress={onPress} />
... |
/*
* GET home page.
*/
exports.index = function(req, res){
res.render('index');
};
exports.main = function(req, res){
res.render('main');
};
exports.deco = function(req, res){
res.render('deco');
}; |
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var pauseCircleO = exports.pauseCircleO = { "viewBox": "0 0 1536 1792", "children": [{ "name": "path", "attribs": { "d": "M768 128q209 0 385.5 103t279.5 279.5 103 385.5-103 385.5-279.5 279.5-385.5 103-385.5-103-279.5-279.5-103-385.5 103-385... |
import styled from 'styled-components';
import Divider from '@material-ui/core/Divider';
const StyledDivider = styled(Divider)`
margin-left: 16px !important;
`;
export default StyledDivider;
|
import StringUtil from '../StringUtil'
import View from '../View'
/**
* Field view
*/
export default class FieldView extends View {
/**
* Constructor
*/
constructor () {
super()
this._$message = null
this._message = null
this._id = StringUtil.uniqueId()
this._first = false
}
/**
... |
'use strict';
// ------------------------------------------------------------------------------
// Requirements
// ------------------------------------------------------------------------------
var rule = require('../rules/controller-as-route');
var RuleTester = require('eslint').RuleTester;
var commonFalsePositives ... |
version https://git-lfs.github.com/spec/v1
oid sha256:9ba8c58b9640c65237b1fb95671725637f01a3b9e460a34c39a5d788a5eb1af9
size 1031
|
var dayRouter = require('express').Router();
var attractionRouter = require('express').Router();
var models = require('../models');
// GET /days
dayRouter.get('/', function(req, res, next) {
console.log('duuude')
... |
/** @constructor */
ScalaJS.c.scala_util_Failure$ = (function() {
ScalaJS.c.java_lang_Object.call(this)
});
ScalaJS.c.scala_util_Failure$.prototype = new ScalaJS.inheritable.java_lang_Object();
ScalaJS.c.scala_util_Failure$.prototype.constructor = ScalaJS.c.scala_util_Failure$;
ScalaJS.c.scala_util_Failure$.prototype... |
'use strict';
angular.module('todoApp', ['todoApp.controller', 'ngAnimate']);
|
'use strict';
/* jshint ignore:start */
/**
* This code was generated by
* \ / _ _ _| _ _
* | (_)\/(_)(_|\/| |(/_ v1.0.0
* / /
*/
/* jshint ignore:end */
var _ = require('lodash'); /* jshint ignore:line */
var util = require('util'); /* jshint ignore:line */
var CredentialListList = requir... |
game.PlayerBaseEntity = me.Entity.extend({
init : function(x, y, settings) { //same like PlayerEntity above for our constructor function
this._super(me.Entity, 'init', [x, y, {
image: "tower",
width: 100,
height:100,
spritewidth: "100",
spriteheight: "100",
getShape: function() {
return (new me... |
//-------------------------------------------------------------
//for myaccount.html
// to add address
//-------------------------------------------------------------
$(document).ready(function(){
$.post("php/address/get_addr.php", { user_id: $.cookie()['user_id'] }, function (dataa, status){
$.getScript("json/addre... |
var SceneConstants = require('../constants/scene-constants');
var AppDispatcher = require('../dispatchers/app-dispatcher');
var ActionTypes = SceneConstants.ActionTypes;
var HubRecieveActions = {
tryListScenes: function() {
AppDispatcher.handleViewAction({
type: ActionTypes.LIST_SCENES_ATTEMPT... |
const mixin = {
mounted() {
}
}
export default mixin
|
/* eslint no-undef: "off",
import/no-extraneous-dependencies: "off"
*/
const assert = require('chai').assert;
const nock = require('nock');
const moltin = require('../../dist/moltin.cjs.js');
const apiUrl = 'https://api.moltin.com';
describe('Moltin authentication', () => {
// Instantiate a Moltin client... |
var express = require('express');
var router = express.Router();
var multer = require('multer');
var upload = multer({ dest: './public/images' })
var mongo = require('mongodb');
var db = require('monk')('localhost/nodeblog');
router.get('/show/:id', function(req, res, next) {
var posts = db.get('accounts');
posts.f... |
/*
Live.js - One script closer to Designing in the Browser
Written for Handcraft.com by Martin Kool (@mrtnkl).
Version 4.
Recent change: Made stylesheet and mimetype checks case insensitive.
http://livejs.com
http://livejs.com/license (MIT)
@livejs
Include live.js#css to monitor css changes only.
... |
version https://git-lfs.github.com/spec/v1
oid sha256:f82fb377ec906859e125a5293b90ee581949ce98f795e7d82c4c817a4e487292
size 3582
|
export class NavigationStateSchema{
constructor(state, index){
this.state = state;
this.index = index;
}
validate() {
return tv4.validateMultiple(this.state, this.schema);
}
get schema(){
return {
"type" : "object",
"properties" : {
... |
// dtm.i = dtm.instr = function () {
// var instr = new Instr();
// return instr;
// };
//
// function Instr() {
// function instr() {
// return this;
// }
//
// var params = {
// dur: 0.1
// };
//
// var m = dtm.music().for(params.dur).rep()
// .amp(dtm.decay().expc(... |
import ListFormRoute from 'ember-flexberry/routes/list-form';
import { Query } from 'ember-flexberry-data';
const { SimplePredicate, StringPredicate, DatePredicate } = Query;
export default ListFormRoute.extend({
/**
Name of model projection to be used as record's properties limitation.
@property modelPro... |
phantom.onError = function(msg) {
stderr.writeLiner(msg);
phantom.exit(1);
};
var ARGS = require("system").args;
var page = require("webpage").create();
var stdout = require("system").stdout;
var stderr = require("system").stderr;
var threadId = parseInt(ARGS[1], 10);
stdout.writeLine("Thread-ID: " + ... |
const validator = require("../library/validator");
const User = require("../entities/user");
const maxAge = 1000 * 60 * 60 * 24 * 7; // 1 week (in miliseconds)
class AuthController {
constructor(authService, userService) {
this.authService = authService;
this.userService = userService;
th... |
(this["webpackJsonp@visa/vds-react"]=this["webpackJsonp@visa/vds-react"]||[]).push([[80],{1592:function(s,a,t){s.exports=t.p+"static/media/illustration-hero-guy-eating-with-man-woman-bg.3d0b3b34.svg"}}]);
//# sourceMappingURL=80.e9e02408.chunk.js.map |
/**
The **Component** class is the base class for all xeogl components.
## Usage
* [Component IDs](#component-ids)
* [Metadata](#metadata)
* [Logging](#logging)
* [Destruction](#destruction)
* [Creating custom Components](#creating-custom-components)
### Component IDs
Every Component has an ID that's uniqu... |
'use strict';
describe('Controller: SettingDetailCtrl', function () {
// load the controller's module
beforeEach(module('amApp'));
var createController,
$controller,
requestHandler,
$httpBackend,
scope;
// Initialize the controller and a mock scope
beforeEach(inject(function ($injector) {
... |
"use strict";
function messageFromResponse(response) {
return `API Error (${response.status}): ${response.statusText}`;
}
/**
* A base error class for API errors
*
* @extends {Error}
*/
export default class ShopifyAPIError extends Error {
constructor(response) {
super(messageFromResponse(response));
t... |
/**
* The MIT License (MIT)
*
* Copyright (c) 2017 GochoMugo <mugo@forfuture.co.ke>
* Copyright (c) 2017 Forfuture LLC <we@forfuture.co.ke>
*/
// built-in modules
const assert = require("assert");
// own modules
const mau = require("../../..");
const constants = require("../../../lib/constants");
const errors ... |
/*!
* UI development toolkit for HTML5 (OpenUI5)
* (c) Copyright 2009-2015 SAP SE or an SAP affiliate company.
* Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
*/
// A renderer for the ScrollBar control
sap.ui.define(function() {
"use strict";
/**
* @class Control renderer.
* @static
*... |
import {map, slice} from "./array";
import {linearish} from "./linear";
import number from "./number";
export default function identity() {
var domain = [0, 1];
function scale(x) {
return +x;
}
scale.invert = scale;
scale.domain = scale.range = function(_) {
return arguments.length ? (domain = map... |
/**
* REST API
* Author: Joshua M. Waggoner
* <rabbitfighter@cryptolab.net>
* @rabbitfighter81
*/
// Imports
var express = require('express');
var bodyParser = require('body-parser');
var statusHandler = require("express-mongoose-status");
// Database Schemas
var Posts = require('../models/post');
var Comments ... |
require("should");
module.exports = function (data) {
data.should.not.equal(null);
data.should.instanceOf(Object);
data.should.have.property('code');
data.code.should.be.String();
data.should.have.property('name');
data.code.should.be.String();
data.should.have.property('divisionId');
... |
/**
* @license Angular v4.2.5
* (c) 2010-2017 Google, Inc. https://angular.io/
* License: MIT
*/
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/common')) :
typeof define === 'function' && define.amd ? define... |
import React, {Component} from 'react';
import Form from '../ui/Form';
import Input from '../ui/Input';
import FormLabel from '../ui/FormLabel';
import {reduxForm} from 'redux-form';
class FilterBox extends Component {
/* eslint react/prop-types: 0 */
render() {
const {fields: {text, showArchived}} = this.prop... |
$(document).ready(function(){
(function() {
var canvas = Martin('martin-home-blur', { autorender: false }),
rainbow,
t = 0, // time starts at 0
hasMousedOver = false,
animatingHelper = false;
Martin.registerEffect('rainbow', function(t) {
this.context.loop(function(x, ... |
version https://git-lfs.github.com/spec/v1
oid sha256:e0f34bac8d54a670402d6584230a8be5a2ec3e7a7f0cea998293f85a36cfeb80
size 2116
|
/**
* @file
* Control flow for the Kalabox installer.
*
* Copyright 2013 Kalamuna LLC
*/
// Dependencies:
var flow = require('nue').flow,
as = require('nue').as,
parallel = require('nue').parallel,
installUtils = require('./install-utils'),
exec = require('child_process').exec,
url = require('... |
'use strict';
var Q = require('q');
var queue = [];
/**
* @constructor
*/
function Queue() {
Object.defineProperty(this, 'length', {
get: getLength
});
}
/**
* @returns {number}
*/
Queue.prototype.push = function() {
return queue.push.apply(queue, arguments);
};
/**
* @returns {T}
*/
Queue.prototype... |
import aggregate from "./base/aggregator";
import toNumber from "./base/type-converter";
function min(accumulator, value, converter) {
let converted = converter(value);
return isNaN(converted) ? false : Math.min(accumulator, converted);
}
export default function minOf(array, callback) {
callback = callb... |
(function() {
var FormatPhone, _, exports, parser, root;
_ = require('lodash');
parser = require('./phone-number-parser');
FormatPhone = {
parsePhoneNumber: function(text, countryCode) {
if (text.length < 0 || text === '') {
return null;
}
return parser.parseNumber(text, country... |
import React from 'react';
import {
View,
StyleSheet,
Navigator,
TouchableOpacity,
TouchableHighlight,
Text,
ScrollView,
Modal,
CameraRoll,
Animated,
ActivityIndicator,
InteractionManager,
TextInput,
Dimensions,
BackAndroid,
Image,
RefreshControl,
ListView,
ToastAndroid,
NativeModules,
} from ... |
describe('Forced March', function() {
integration(function() {
describe('when revealed', function() {
beforeEach(function() {
const deck = this.buildDeck('targaryen', [
'Forced March (SoD)', 'A Noble Cause',
'Hedge Knight', 'Hedge Knight', ... |
var express = require('express');
var bodyParser = require("body-parser");
var knexConf = require("../../../knexConf");
var knex = require('knex')(knexConf);
var joinjs = require("join-js");
var resultMaps = require("../resultMaps/maps");
var Promise = require('bluebird');
var _ = require("lodash");
app = express();
... |
import {handleActions} from 'redux-actions';
const defaultValue = true;
function onExpandedLocationChange(_, action) {
return action.payload.query.expanded !== 'false';
}
export default handleActions({
'@@router/LOCATION_CHANGE': onExpandedLocationChange
}, defaultValue);
|
class ExDate {
now() {
return Date.now();
}
}
class TokenBucket {
constructor(date, hearing_time, max_token) {
this.date = date;
var now = date.now();
this.hearing_time = hearing_time;
this.b = max_token;
this.token = max_token;
this.instanciated_at ... |
/**
* Hydro configuration
*
* @param {Hydro} hydro
*/
module.exports = function(hydro) {
hydro.set({
suite: 'lift-result',
timeout: 500,
plugins: [
require('hydro-chai'),
require('hydro-bdd')
],
chai: {
chai: require('chai'),
plugins: [ require('chai-spies') ],
... |
// block specific req number
export const BLACK_LIST = ['183787BR', '183788BR', '183789BR', '184340BR', '184341BR', '184343BR', '184344BR', '184345BR', '184346BR', '188212BR', '188213BR', '188214BR', '188215BR', '188216BR', '188313BR', '188314BR', '188312BR', '188315BR', '188212BR', '188213BR', '188214BR', '188215BR', ... |
;(function(){
var shout;
module('shout', {
setup: function(){
shout = new Shout();
},
teardown: function(){
shout = null;
}
});
test('single event on', 1, function(){
var test = false;
shout.on('foo', function(){
test = true;
});
shout.emit('foo');
equal(... |
import { REPLY_RECEIVED } from '_utils/promiseMiddleware';
import { SET_PENDING, CLEAR_ALL_PENDING } from './constants';
export default (
state = {
pending: [],
},
action,
) => {
if (action.stage && action.stage !== REPLY_RECEIVED) return state;
switch (action.type) {
case SET_PENDING:
return ... |
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var code_1 = require("./code");
exports.States = code_1.States;
|
/**
* @description
* <%= controllerName %>.controller
* <%= whatIsThisController %>
**/
angular.module('<%= controllerName %>.controller', [
'humpback.controllers'
])
.controller( '<%= ControllerName %>', function <%= ControllerNameLong %> ( $scope ) {
}); |
'use strict';
var ld = require('lodash');
exports.configureEnv = function () {
global.ROOT_DIR = '.';
global.APP_NAME = require('../package.json').name;
};
exports.deepCopy = function (obj) {
return JSON.parse(JSON.stringify(obj));
};
exports.range = function (n) {
return ld.map(new Array(n), function (elm,... |
const arrayPrototype = Array.prototype;
if (arrayPrototype.fill == null) {
// polyfill based on:
// https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Array/fill
Object.defineProperty(arrayPrototype, 'fill', {
value(value, start, end) {
if (this == null) {
... |
export default function($resource) {
"ngInject";
return $resource('/api/v1/goal/:id/', { id: '@_id' }, {});
};
|
/*! d3-corrplot - v0.0.1 - 2015-03-01 - Jeremy Kahn */
;(function (global) {
// Compiler directive for UglifyJS. See Corrplot.const.js for more info.
if (typeof DEBUG === 'undefined') {
DEBUG = true;
}
// Corrplot-GLOBAL CONSTANTS
//
// These constants are exposed to all Corrplot modules.
// GLOBAL is a referen... |
const { src, dest, task, series } = require('gulp');
const fs = require('fs');
const del = require('del');
const gulpif = require('gulp-if');
const replace = require('gulp-replace');
const postcss = require('gulp-postcss');
const autoprefixer = require('autoprefixer');
const uglify = require('gulp-uglify');
const clea... |
// Example
var ourArray = ["John", 23];
// Only change code below this line.
var myArray = [];
|
import React from 'react';
import styled from 'styled-components';
const LogoContainer = styled.div`
`;
const StyledLogo = styled.svg`
width: 100px;
`;
const LogoTextContainer = styled.div`
display: inline-block;
height: 100%;
font-size: 30px;
margin: 0.02em;
vertical-align: middle;
`;
const SvgLogo = () =... |
var students = [
{
first_name: 'Bob', last_name: 'Harrison', gender: 'Male',
address: '1197 Thunder Wagon Common, Cataract, RI, 02987-1016, US, (401) 747-0763',
mood: "Happy", country: 'Ireland'
}, {
first_name: 'Mary', last_name: 'Wilson', gender: 'Female',
age: 11, addr... |
var express = require('express');
var path = require('path');
var favicon = require('serve-favicon');
var logger = require('morgan');
var cookieParser = require('cookie-parser');
var bodyParser = require('body-parser');
var partials = require('express-partials');
var routes = require('./routes/index');
var app = exp... |
const mongoose = require('mongoose');
let Room = require('../models/roomRent');
let PropertyRent = require('../models/propertyRent');
let login = require('../helpers/login');
const checkAuth = (req,res, next) => {
let method = req.method;
let hasParam = req.path !== '/';
// if (method == "GET") next()
if (req... |
import fetch from 'focus-core/network/fetch';
import movieUrl from '../config/server/movies';
import omit from 'lodash/object/omit';
export default {
loadMovie(id) {
console.log(`[MOVIE] call loadMovie(${id}) method`);
return fetch(movieUrl.load({urlData: {id}}), {isCORS: true});
},
loadMov... |
///import core
///import uicore
///import ui/mask.js
///import ui/button.js
(function() {
var utils = baidu.editor.utils,
domUtils = baidu.editor.dom.domUtils,
uiUtils = baidu.editor.ui.uiUtils,
Mask = baidu.editor.ui.Mask,
UIBase = baidu.editor.ui.UIBase,
Button = baidu.editor.ui.Button... |
'use strict';
angular.module('animatedBirdsDirective', [])
.directive('animatedBirds', function($window) {
return {
restrict: 'A',
compile: function() {
return function(scope, lElem) {
var tl = new TimelineMax(
{
repeat: 0,
delay: 1,
onComplete: fu... |
#!/usr/bin/env node
import meow from 'meow';
import emptyTrash from 'empty-trash';
meow(`
Usage
$ empty-trash
`, {
importMeta: import.meta,
});
emptyTrash();
|
const socketio = require('socket.io')
const data = require('../data/tasks')
exports.listen = function (server) {
io = socketio.listen(server)
io.sockets.on('connection', function (socket) {
console.log('Connection created')
createTask(socket)
displayAllTask(socket)
})
const createTask = (socket) =>... |
/* CalendarController:
This controller handles the calendar functionality in the tracks page. The tracks.html file makes
use of this calendar controller
1) We have made use of the calendar directive to achieve this.
2) There are 4 important functions of this controller(PrevMonth,NextMonth,DateClicked,Populating the... |
function a(){return function(c){var d=Array.prototype.slice.call(arguments,1),b="__"+(c.name||Math.random());return function(){if(arguments.callee[b])return arguments.callee[b];arguments.callee[b]=this;c.apply(this,d.length?d:arguments)}}}"function"===typeof define&&define.amd?define(a):"object"===typeof exports?module... |
const models = require('../../models');
let Project = models.projects;
let User = models.users;
let ProjectAssignment = models.project_assignments;
module.exports = function(connection, done) {
connection.createChannel(function(err, ch) {
console.log(err);
var ex = process.env.ex;
var queue = 'chiepherd.... |
// libraries
import { combineReducers } from 'redux';
// Reducers
import App from './app';
const rootReducer = combineReducers({
App: App
});
export default rootReducer;
|
import requestToQualifiedRelationQuoted from '../query/requestToQualifiedRelationQuoted';
import requestToWhereClause from '../query/requestToWhereClause';
import sql, {raw as rawSql} from '../sqlTemplate';
export default function requestToDeleteStatement(req) {
const qualifiedRelationQuoted = rawSql(requestToQual... |
var Knex = require('knex')
var knexConfig = require('../knexfile')[process.env.NODE_ENV || 'development']
var knex = Knex(knexConfig)
module.exports = {
getMinions
// isOnsite,
// isOffsite
}
//get all minions
function getMinions() {
return knex('edaRegister')
}
// //check if onsite
// function isOnsite() {
... |
'use strict';
/**
* Module dependencies.
*/
var _ = require('lodash');
var walk = require('walk');
var fs = require('fs');
var path = require('path');
var util = require('./util');
var chalk = require('chalk');
var indexer = {
// The JSON of the index.
_index: undefined,
// Last time the index was
// pul... |
// Regular expression that matches all symbols in the Manichaean block as per Unicode v9.0.0:
/\uD802[\uDEC0-\uDEFF]/; |
let btn = document.getElementById('btn');
let body = document.body;
btn.addEventListener('click', ev => {
var popup = new Promise((res, rej) => {
btn.disabled = true;
let div = document.createElement('div');
div.className += ' popup';
div.innerHTML = 'redirecting to telerik academy'... |
////////////////////////////////////////////////
/* Provided Code - Please Don't Edit */
////////////////////////////////////////////////
'use strict';
function getInput() {
console.log("Please choose either 'rock', 'paper', or 'scissors'.")
return prompt();
}
function randomPlay() {
var randomNumber =... |
import '../assets/stylesheets/index.css';
import React from 'react';
import BrowserHistory from 'react-router/lib/BrowserHistory';
import HashHistory from 'react-router/lib/HashHistory';
import Root from './Root';
// Use hash location for Github Pages
// but switch to HTML5 history locally.
const history = process.env... |
import gulp from 'gulp'
import mocha from 'gulp-mocha'
import gutil from 'gulp-util'
import babel from 'gulp-babel'
gulp.task('test', () => {
return gulp.src('./test/**/*.js')
.pipe(mocha({ compilers: { js: babel } }))
.on('error', gutil.log)
})
gulp.task('test:watch', () => {
gulp.watch(['./test/**/*.js'... |
module.exports = {
/** Used to map method names to their aliases. */
'aliasMap': {
'forEach': ['each'],
'forEachRight': ['eachRight']
},
/** Used to map method names to their iteratee ary. */
'aryIterateeMap': {
'assignWith': 2,
'cloneDeepWith': 1,
'cloneWith': 1,
'countBy': 1,
'... |
import { Animal, AnimalState } from "./animal.js";
import { State } from "./states.js";
import { map, scene, BlockSize } from "./global.js";
import { Block } from "./map.js";
import { Message, MessageTypes, SoundMessage } from "./message.js";
import { Global } from "./global.js";
import { Deer, DeerDead } from "./deer... |
'use strict';
/**
* Module dependencies.
*/
var config = require('../config'),
chalk = require('chalk'),
path = require('path'),
_ = require('lodash'),
mongoose = require('mongoose');
mongoose.Promise = global.Promise;
// Load the mongoose models
module.exports.loadModels = function() {
// Globbing model file... |
"use strict";
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Refl... |
#!/usr/bin/env node
let http = require('http'),
cp = require('child_process'),
qs = require('querystring'),
result = '';
http.createServer((req, res) => {
if(req.url != '/') {
err(res);
return;
}
console.log(req.headers);
console.log('');
switch(req.method) {
case 'GET':
... |
import {partial} from 'lodash'
export function register (method, path, ...middleware) {
return (target, key) => {
const { routes = [] } = target
routes.push({
path,
method,
middleware,
action: key
})
target.routes = routes
}
}
export const all = partial(register, 'all')
ex... |
import ExtandableError from 'es6-error';
class ActionCreatorError extends ExtandableError {
constructor(message, {actionCreator, actionType, data}) {
super(message);
this.action = { creator: actionCreator
, type : actionType};
this.data = data;
}
}
export d... |
/**
* File socket.js
* Service class for Socket
*/
angular.module('services.socket', []);
angular.module('services.socket').factory('socketContainer', function(){
var socket = io();
var socketService = {};
socketService.getSocket = function() {
return socket;
};
return socketService;
});
|
/* jshint devel: true */
/* jshint browser: true */
/* jshint -W097 */
/* global io */
"use strict";
// TODO: Fix shell offset when turret rotated
var imageScale = 0.20;
var shellRange = 10000;
var traverseSpeed = 0.03;
var turretSpeed = 0.03;
var fireWaitDelay_ms = 2000;
var tankUpdateThreshold_ms = 5000;
var ca... |
exports.domain = 'http://api.douban.com';
exports.res =
[{
route: '/book/:id',
method: 'GET',
url: '/v2/book/1220562',
params: [{
name: 'id',
type: 'Number',
maxLength: 10,
minLength: 6,
reg: /^\d{6,10}$/,
message: '必须是6-10位的数字'
}]
}]; |
var m = require('mithril')
var Tabs = require('./tabs')
var Sidebar = require('./sidebar')
var Footer = require('./footer')
var Details = require('./details')
var Preferences = require('./preferences')
var Loading = require('./loading')
var rendererStore = require('../rendererStore');
var config = require('electron').r... |
module.exports = function(params, dynamo) {
return dynamo.raw.deleteTable(params).promise().then(function (response) {
return response;
});
};
|
var Cachematrix;
(function (Cachematrix) {
var WeatherApp;
(function (WeatherApp) {
var ViewModels;
(function (ViewModels) {
var HomePageVM = (function () {
function HomePageVM(data) {
var _this = this;
this.today = ko.computed(... |
import 'src/style/index.css';
import 'modules/env';
import ReactDOM from 'react-dom';
import { loadableReady } from '@loadable/component';
import App from './App';
import AppError from 'components/AppError';
const elRoot = document.getElementById('app');
const render = (Component) => {
// eslint-disable-next-line n... |
import Directive from '../../directive'
import { replace, getAttr, isFragment } from '../../util/index'
import { compile, compileRoot, transclude } from '../../compiler/index'
export default function (Vue) {
/**
* Update v-ref for component.
*
* @param {Boolean} remove
*/
Vue.prototype._updateRef = fu... |
import React from 'react';
import PropTypes from 'prop-types';
import BaseView from '../../utils/rnw-compat/BaseView';
const propTypes = {
children: PropTypes.node.isRequired,
};
const ToastHeader = React.forwardRef((props, ref) => (
<BaseView {...props} ref={ref} essentials={{ className: 'toast-header' }} />
));... |
let config = {
TOTAL_DURATION: 20, // in seconds
BASE_FREQ: 35,
COL_COUNT: 40,
ROW_COUNT: 30,
BOARD_WIDTH: 2000,
BOARD_HEIGHT: 1500,
VISUALIZER_FRAME_RATE: 50,
gridlines: false,
midify: false,
frequencies: false,
paletteLabels: false,
scales: {
aeolian: [0, 2, 3, 5, 7, 8, 10],
blues: [0,... |
// Load required packages
var mongoose = require('mongoose');
var bcrypt = require('bcrypt-nodejs');
// Define our user schema
var UserSchema = new mongoose.Schema({
username: {
type: String,
unique: true,
required: true
},
email: {
type: String,
required: true
},
password: {
type: St... |
version https://git-lfs.github.com/spec/v1
oid sha256:5b951f77463e33578e159bfb3d8f35ef4ec677392ddb23e17eeea74bd0aed9c4
size 13668
|
Pebble.addEventListener("ready",
function(e) {
console.log("JavaScript app ready and running!");
//Pebble.showSimpleNotificationOnPebble("JavaScript Event Listener", "is ready");
}
);
// Send command to XBMC JSON-RPC API
function doPOST(data)//, on_load_function)
{
var req = new XMLHttpRequest();
// TODO: us... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.