code stringlengths 2 1.05M |
|---|
/*global defineSuite*/
defineSuite([
'Scene/PolylineCollection',
'Core/BoundingSphere',
'Core/Cartesian3',
'Core/Cartographic',
'Core/Color',
'Core/Math',
'Renderer/ClearCommand',
'Scene/Material',
'Scene/SceneMode',
'Specs/createCamera',
... |
import { map } from './utils';
export default parser;
function parser(tokens) {
const ops = tokens.reduce((...args) => {
const [ , { parse, type } ] = args;
try {
return parse(...args);
} catch(e) {
throw new Error(`Unknown token type: ${type}`);
}
}, []);
return ops;
}
|
"use strict";
var inherits = require('util').inherits;
var Token = require('./core').Token;
var FunctionStart = function (ctx, name, args, endImmediately, isCommented, opt_isInit, opt_body) {
this.ctx = ctx;
this.name = name;
this.args = args;
this.endImmediately = endImmediately;
this.isCommented = isCommented;... |
/*! Copyright (c) 2011 Piotr Rochala (http://rocha.la)
* Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php)
* and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses.
*
* Version: 1.3.0
*
*/
(function($) {
jQuery.fn.extend({
slimScroll: function(options) {
... |
var misc = require('./misc');
var AssertionErrror = require('./errors').AssertionErrror;
var AWS = require('aws-sdk');
function Source(config) {
if(typeof config === 'undefined' || config === null) {
throw new AssertionErrror('You must pass a configuration object.');
}
var lowConfig = new misc.LowPropertiesObjec... |
import test from 'ava';
import enumerate from '../../src/adapters/enumerate';
test('enumerate returns the values and their index', t => {
const iter = enumerate(['a', 'b', 'c']);
t.is(typeof iter.next, 'function');
t.deepEqual(iter.next().value, [0, 'a']);
t.deepEqual(iter.next().value, [1, 'b']);
t.deepEqu... |
var allImg = document.getElementsByTagName("img"), i = 0, img;
var images = ["http://www.dogbreedinfo.com/images12/BorderCollie6yearsKaya.JPG",
"http://www.dogbreedslist.info/uploads/allimg/dog-pictures/Border-Collie-3.jpg",
"http://nextranks.com/data_images/dogs/border-collie/border-collie-05.jpg",
"http:... |
var gulp = require('gulp');
var clip = require('gulp-clip-empty-files');
var tsd = require('gulp-tsd');
var del = require('del');
var sync = require('browser-sync');
var seq = require('run-sequence');
var changed = require('gulp-changed');
var sass = require('gulp-sass');
var sourcemaps = require('gulp-sourcemaps');
va... |
const isFunction = function(o){ return typeof o === 'function'; };
const defaults = require('./defaults');
const assign = require('./assign');
const dagre = require('dagre');
// constructor
// options : object containing layout options
function DagreLayout( options ){
this.options = assign( {}, defaults, options );
... |
async function a() {
var mongoCollection = require('./models/mongo-collection');
let collection1 = new mongoCollection(1);
console.log('first:', await collection1.getCollection());
console.log('second:', await collection1.getCollection())
};
a(); |
// This is a manifest file that'll be compiled into application.js, which will include all the files
// listed below.
//
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
// or any plugin's vendor/assets/javascripts directory can be referenced here using a relative ... |
// Find the missing letter in the passed letter range and return it.
// If all letters are present in the range, return undefined.
function fearNotLetter(str) {
for (var i = 0; i < str.length; i++) {
var currentCode = str.charCodeAt(i);
if (currentCode !== str.charCodeAt(0) + i) {
v... |
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];return s(n?n:e)},f,f.exports,e,t,n,r)}return n[o].exports... |
var WGS =
/******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId])
/******/ return ins... |
//Completed 7/28/2014 by Ralph Samuel
describe("About Expects", function() {
//We shall contemplate truth by testing reality, via spec expectations.
it("should expect true", function() {
expect(true).toBeTruthy(); //This should be true
});
//To understand reality, we must compare our expectations agains... |
var ExtractTextPlugin = require('extract-text-webpack-plugin')
var pathUtil = require('./path-util.js')
var vueTyperStyles = pathUtil.getPathFromRoot('src/vue-typer/styles')
var demoStyles = pathUtil.getPathFromRoot('src/demo/styles')
var cssLoader = 'css-loader?minimize'
var sassLoader = `sass-loader?includePaths[]=... |
var request = require('request');
var nlp = {
parseText: function(text, callback){
if (text.length >250){
return false; //"ERROR: input length greater than 250 characters. Please parse one sentence at a time";
}
else {
var url = 'http://nlp.naturalparsing.com/api/parse?input=?format=json&json... |
/*
*
* CallLogs reducer
*
*/
import { fromJS } from 'immutable';
import {
GET_TW_CALLS_LIST,
GET_TW_CALLS_LIST_SUCCESS,
GET_TW_CALLS_LIST_ERROR,
} from './constants';
const initialState = fromJS({
loading: null,
error: null,
calls: { data: null },
});
function callLogsReducer(state = initialState, ac... |
//Lets require/import the HTTP module
var http = require('http');
var redis = require('redis');
var client = redis.createClient({host: "redis"});
client.on("error", function (err) {
console.log("Error " + err);
});
//Lets define a port we want to listen to
const PORT=8080;
//We need a function which handles reque... |
module("wysihtml5.dom.getParentElement", {
setup: function() {
this.container = document.createElement("div");
}
});
test("Basic test - nodeName only", function() {
this.container.innerHTML = "<ul><li>foo</li></ul>";
var listItem = this.container.querySelector("li"),
textNode = listIte... |
$(document).ready(function(){
$('nav.main a').click(function(e){
e.preventDefault();
console.log(e);
var section = $(this).data('link');
$('html, body').animate({
scrollTop: ($('.'+ section).offset().top) - 55
}, 500);
});
$('a[rel="external"]').clic... |
'use strict';
module.exports = (function () {
var pluginName = 'mol',
hoek = require('hoek'),
findit = require('findit'),
Promise = require('bluebird'),
path = require('path'),
defaults = {
tree: true,
base: './'
};
function getPromise(mainPath, tree, scope, registerCb) {
ret... |
/**
* Created by khuongdt on 11/30/2015.
* Author : khuongdt
* Copyright @ 2015 by OneSoft.,JSC
*/
goog.provide('com.onesoft.livetube.entity.CSListTopFollowed');
goog.require('bigfox.Global');
goog.require('bigfox.core.base.BaseMessage');
goog.require('com.onesoft.livetube.base.LiveTag');
com.onesoft.livetube.... |
'use strict';
angular.module('ffffng')
.controller('NewNodeCtrl', function ($scope, Navigator, NodeService, $routeParams, _, config) {
$scope.config = config;
$scope.node = {};
$scope.saved = false;
_.each(['hostname', 'key', 'mac'], function (field) {
var value = $routeParams[field];
... |
var fs = require('fs')
var pkg = require('../package.json')
var banner = '/*!\n' +
'* js-data\n' +
'* @version ' + pkg.version + ' - Homepage <http://www.js-data.io/>\n' +
'* @author js-data project authors\n' +
'* @copyright (c) 2014-2016 js-data project authors\n' +
'* @license MIT <https://github.com/js-d... |
/**
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
* @flow
*/
import type {ReactElement} from 'shared/ReactElementType';
import type {
ReactProvider,
ReactConsumer,
ReactCont... |
var Gazerstrator = require('./gazerstrator.js');
var File = require('vinyl');
var gutil = require('gulp-util');
var path = require('path');
var minimatch = require('minimatch');
var through = require('through2');
var plumber = require('gulp-plumber');
var fs = require('fs');
var readContent = function() {
return thro... |
import TestPromise from 'jasmine-es6/helpers/promise';
const implementation = {
fetch() {
return new Promise(() => null);
},
async doStuff() {
this.showSpinner = true;
await this.fetch('https://google.com');
this.showSpinner = false;
}
};
describe('Promise', () => {
it('works', async () => {... |
var searchData=
[
['floataddunit',['FloatAddUnit',['../class_float_add_unit.html',1,'']]],
['floatmultunit',['FloatMultUnit',['../class_float_mult_unit.html',1,'']]],
['functionalunit',['FunctionalUnit',['../class_functional_unit.html',1,'']]],
['functionalunitexception',['FunctionalUnitException',['../class_fu... |
import { HTTP } from 'meteor/http';
const gatewayURL = 'https://omni.rocket.chat';
export default {
enable() {
const result = HTTP.call('POST', `${ gatewayURL }/facebook/enable`, {
headers: {
authorization: `Bearer ${ RocketChat.settings.get('Livechat_Facebook_API_Key') }`,
'content-type': 'application/... |
// This is a manifest file that'll be compiled into application.js.
//
// Any JavaScript file within this directory can be referenced here using a relative path.
//
// You're free to add application-wide JavaScript to this file, but it's generally better
// to create separate JavaScript files as needed.
//
//= require... |
<%= variable %> = project_path() |
// Thanks to Werner Van Belle from Bpmdj for the implementation of the flanger.
// https://werner.yellowcouch.org
Modules.Flange = class Flange extends AudioModule {
constructor (con) {
super(con);
this.className = "Flange";
this.prerun = true;
this.numberOfInputs = 7;
this.numberOfOutputs= 1;
this.c... |
/**
* This class will contain all the options available on the Gisplay API.
* @see Diogo's thesis page 50-52
*/
class GisplayOptions {
/**
* Creates a new Options object. User options take precedence over default options.
* @param {Object} userOptions - The user defined options.
* @param {string}... |
import { epgpTotal } from 'nobreaks/helpers/epgp-total';
import { module, test } from 'qunit';
module('Unit | Helper | epgp total');
// Replace this with your real tests.
test('it works', function(assert) {
let result = epgpTotal([42]);
assert.ok(result);
});
|
// All material copyright ESRI, All Rights Reserved, unless otherwise specified.
// See https://js.arcgis.com/4.8/esri/copyright.txt for details.
//>>built
define("require exports ../../../core/tsSupport/extendsHelper ../../../core/ObjectPool ./TileAgent ./tileUtils".split(" "),function(h,k,d,e,f,g){return function(c){... |
'use strict';
import {
DeviceEventEmitter,
NativeModules,
requireNativeComponent,
} from 'react-native';
import {PropTypes} from 'react';
const {WebRTCModule} = NativeModules;
const RTCView = {
name: 'RTCVideoView',
propTypes: {
/**
* Indicates whether the video specified by {@link #streamURL} sh... |
(function (namespace) {
"use strict";
var block_input = {};
namespace['states'] = {
transitioning: block_input,
walking: block_input,
standing: (function () {
var xDown = null, yDown = null;
var keydownHandler = function (e) {
var didMove ... |
/**
* SimpleBar.js - v5.0.2-corejs2
* Scrollbars, simpler.
* https://grsmto.github.io/simplebar/
*
* Made by Adrien Denat from a fork by Jonathan Nicol
* Under MIT License
*/
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof defi... |
/**
* Listens for the app launching then creates the window
*
* @see http://developer.chrome.com/apps/app.window.html
*/
var appWin = null;
var prevBounds = null;
chrome.app.runtime.onLaunched.addListener(function() {
chrome.app.window.create('web/main.html', {
id: "TeslaApp",
width: 400,
height: 600,
... |
const {exec} = require('child_process');
const path = require('path');
const {expect} = require('chai').use(require('chai-fs'));
const generateController = require('../generate/generate.controller');
const generateModel = require('../generate/generate.model');
const generateRoute = require('../generate/generate.route')... |
import getClearMemory from "./clearMemory";
import getClearState from "./clearState";
class Interpreter {
parseAddress(addr, registerState) {
const tokens = addr.split(/[()]/);
if (tokens.length != 3)
throw `ERROR: address ${addr} is malformed.`
// console.log(tokens);
c... |
'use strict';
var path = require('path');
var isThere = require('is-there');
var _ = require('lodash');
var hasJSHintCache;
var hasJSCSCache;
exports.getProjectDirectory = function(userConfig) {
// This parameter is useful only when npm link is used
if (_.has(userConfig, 'projectDirectory')) {
return... |
angular.module("ngLocale", [], ["$provide", function($provide) {
var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"};
$provide.value("$locale", {
"DATETIME_FORMATS": {
"AMPMS": [
"AM",
... |
// Ionic Starter App
// angular.module is a global place for creating, registering and retrieving Angular modules
// 'starter' is the name of this angular module example (also set in a <body> attribute in index.html)
// the 2nd parameter is an array of 'requires'
// 'starter.controllers' is found in controllers.js
ang... |
module.exports = {
input: `- first\n- second\n- third\n- first\n- second\n- third`,
output: [
{
type: 'ul',
children: [
{
type: 'li',
text: 'first'
},
{
type: 'li',
... |
module.exports = class extends think.Model {
get pk() {
return 'typeid';
}
};
|
module.exports = {
"env": {
"browser": true,
"commonjs": true,
"es6": true
},
"parserOptions": {
"ecmaFeatures": {
"experimentalObjectRestSpread": true
},
"sourceType": "module"
},
"globals" : {
"window": true
},
"extends": ["eslint:recommended"],
"rules": {
"indent... |
"use strict";
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
var _jsxRuntime = require("../../lib/jsxRuntime");
var _extends2 = _interopRequireDefault(require("@babel/runtime/hel... |
import { Cell } from './Cell.js';
import { AABB } from '../math/AABB.js';
import { Vector3 } from '../math/Vector3.js';
const clampedPosition = new Vector3();
const aabb = new AABB();
const contour = new Array();
/**
* This class is used for cell-space partitioning, a basic approach for implementing
* a spatial index... |
'use strict';
/**
* Module dependencies.
*/
var should = require('should'),
mongoose = require('mongoose'),
User = mongoose.model('User'),
Scoresheet = mongoose.model('Scoresheet');
/**
* Globals
*/
var user, scoresheet;
/**
* Unit tests
*/
describe('Scoresheet Model Unit Tests:', function() {
beforeEach(f... |
import v4 from 'uuid/v4';
import { SHOW_TOAST, DISMISS_TOAST } from './actionTypes';
import initialState from './initialState';
const reducer = (state = initialState, action) => {
switch (action.type) {
case SHOW_TOAST: {
const newState = [...state];
newState.push({ ...action.payload, id: v4() ... |
// Copyright (c) 2012 Ecma International. All rights reserved.
// Ecma International makes this code available under the terms and conditions set
// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
// "Use Terms"). Any redistribution of this code must retain the above
// copyright and this n... |
import React from 'react';
import { Link } from 'react-router';
export default class MainLayout extends React.Component {
constructor() {
super();
}
render() {
return (
<div id="main_layout">
{this.props.children}
</div>
);
}
}
|
import mongoose from 'mongoose';
import dotenv from 'dotenv';
dotenv.config();
const uri = `mongodb://${process.env.MONGO_USERNAME}:${process.env
.MONGO_PASSWORD}@${process.env.MONGO_ADDRESS}`;
mongoose.Promise = global.Promise;
mongoose.connect(uri, { useMongoClient: true, reconnectTries: 30 });
mongoose.connect... |
/**
* @file create-icon.js
*/
import * as Dom from '../utils/dom.js';
import mergeOptions from '../utils/merge-options.js';
import Config from '../../config.js';
import Icon from './icon.js';
class CreateIcon extends Icon {
constructor(options) {
options = mergeOptions(CreateIcon.prototype.options_, options);
... |
version https://git-lfs.github.com/spec/v1
oid sha256:55007d5cd3f474a018d8420c62f25237f5d4e6da5362a2989f95f6ca42b119b4
size 3694
|
import { Icon } from "@blueprintjs/core";
import React from "react";
import ToolbarItem from "./ToolbarItem";
import { connectToEditor } from "../withEditorProps";
export default connectToEditor(editorState => {
return {
readOnly: editorState.readOnly
};
})(({ toolbarItemProps, readOnly, toggleReadOnlyMode }) ... |
$(document).ready(function () {
var POLLING_INTERVAL_MSEC = 500;
var SCROLL_MSEC = POLLING_INTERVAL_MSEC / 2;
var AUTOSCROLL_ENABLED = false;
//
// Prepare the comboboxes with loggers and levels
//
function createComboBox(loggerName, loggerLevel) {
var s = $('<select />', {id: loggerName});
levels = [... |
/**
* @file Metadata.js
* @author Tony Ngan
* @desc An abstraction for metadata of identity provider and service provider
*/
var fs = require('fs');
var samlLib = require('./SamlLib');
var namespace = require('./urn').namespace;
var certUse = require('./urn').wording.certUse;
var Utility = require('./Utility');
/**
* @... |
const sinon = require("sinon")
const locals = require("../../lib/app/locals")
describe("locals", function () {
let req
let res
let next
beforeEach(function () {
req = { query: {} }
res = { locals: { sd: {} } }
next = sinon.stub()
})
it("escapes the error message html", function () {
req.q... |
import * as React from 'react'
import {fireEvent, render, screen} from '@testing-library/react'
import Downshift from '../'
import setA11yStatus from '../set-a11y-status'
import * as utils from '../utils'
jest.useFakeTimers()
jest.mock('../set-a11y-status')
jest.mock('../utils', () => {
const realUtils = jest.requir... |
import assert from 'power-assert';
import {find} from 'hoardom';
import test from '../../helper/test';
import role from '../../../lib/utility/aria/role';
describe('role', () => {
it('returns the role explicitly associated with an element', async () => {
await test(
`
<div role="list">Lorem ipsum</div... |
// Copyright IBM Corp. 2015. All Rights Reserved.
// Node module: strong-agent
// US Government Users Restricted Rights - Use, duplication or disclosure
// restricted by GSA ADP Schedule Contract with IBM Corp.
'use strict';
var instrument = require('./oracle');
var proxy = require('../proxy');
module.exports = func... |
'use strict';
describe('GET /account/new_token', () => {
db.sync();
db.create(['user']);
let user;
beforeEach(() => {
user = factory.buildSync('user');
return user.save();
});
it('returns a new token', done => {
api.account(user).generateNewToken()
.expect(200, (err, res) => {
if (... |
import React, { Component } from 'react';
import ObjectDescription from './ObjectDescription';
import ObjectPreview from './ObjectPreview';
export default class ObjectInspector extends Component {
propTypes: {
name: PropTypes.string,
data: PropTypes.object,
depth: PropTypes.number,
objectinspectori... |
function cocktail_sort_draw(gs, arr)
{
var lower = 1;
var upper = arr.length - 1;
var swapped;
while (lower <= upper)
{
swapped = false;
var nlower = upper;
var nupper = lower;
for (var j = lower; j <= upper; j++)
{
gs.compare([j, j + 1]);
if (arr[j] > arr[j + 1])
{
... |
window.addEventListener('load', pageInit);
function pageInit() {
createBoxes();
window.addEventListener('keypress', function(e) {
if(e.key == 'k') {
animateFirstBox();
}
});
}
function createBoxes() {
window.container = document.querySelector('#menuContainer');
f... |
/**
* Created by tobi on 21.11.2015.
*/
'use strict';
angular.module('spc')
.controller('UserManagerCtrl', function ($scope, $http, Auth, User) {
// Use the User $resource to fetch all users
$scope.users = User.query();
$scope.delete = function(user) {
User.remove({ id: user._id });
angul... |
import 'babel-polyfill';
import EdgeGrid from 'edgegrid';
import dotenv from 'dotenv';
import fs from 'fs';
import { setLocalConfig, setApiConfig, setValueMap, setSkipBehaviors, generateConf } from './src/akamai-nginx.js';
(async function() {
// load .env vars
dotenv.config();
let mode = process.env.AKA_... |
<DropdownButton id="dropdown-item-button" title="Dropdown button">
<Dropdown.ItemText>Dropdown item text</Dropdown.ItemText>
<Dropdown.Item as="button">Action</Dropdown.Item>
<Dropdown.Item as="button">Another action</Dropdown.Item>
<Dropdown.Item as="button">Something else</Dropdown.Item>
</DropdownButton>;
|
/******/ (function(modules) { // webpackBootstrap
/******/ // install a JSONP callback for chunk loading
/******/ var parentJsonpFunction = window["webpackJsonp"];
/******/ window["webpackJsonp"] = function webpackJsonpCallback(chunkIds, moreModules) {
/******/ // add "moreModules" to the modules object,
/******/ ... |
import React from 'react';
import PropTypes from 'prop-types';
import styled from 'styled-components';
import { compose } from 'redux';
import { connect } from 'react-redux';
import { withRouter } from 'react-router';
import queryString from 'query-string';
import EditView from '../moments/EditView';
import Loading fr... |
'use strict';
/* Directives */
angular.module('app.directives', [])
.directive('appVersion', ['version', function(version) {
return function(scope, elm, attrs) {
elm.text(version);
};
}])
.directive('chart', function() {
return {
restrict: 'A',
template: '<div style="width:100... |
var gulp = require('gulp');
var path = require('path');
var $ = require('gulp-load-plugins')();
var del = require('del');
// set variable via $ gulp --type production
var environment = $.util.env.type || 'development';
var isProduction = environment === 'production';
var webpackConfig = require('./webpack.config.js').g... |
# Authentication Setup
> Passport + JsonWebToken + Redis enabled robust Authentication & Authorization for Restgoose
## Setup
1. Install Redis Server
a. [Windows](https://github.com/rgl/redis/downloads)
b. Mac OS X ``brew install redis``
c. [Linux](https://www.digitalocean.com/community/tutorials... |
module.exports = {
// This code will be compiled
entry: "./app/app.js",
// Then output into this file
output: {
filename: "public/bundle.js"
},
// This will be what we do
module: {
loaders: [
{
test: /\.jsx?$/,
exclude: /(node_modules|bower_components)/,
loader: 'b... |
import React, { Component } from 'react';
import Link from './Link'
class NavBar extends Component {
render() {
return (
<div className="NavBar">
<span>NavBar</span>
<div className="link-container">
<Link />
<Link />
<Link />
</div>
... |
/*
* forbject
* http://github.com/yawetse/forbject
* inspired by: https://github.com/serbanghita/formToObject.js
* Copyright (c) 2014 Yaw Joseph Etse. All rights reserved.
*/
'use strict';
var events = require('events'),
extend = require('util-extend'),
util = require('util');
/**
* A module that represents a... |
'use strict';
const http = require('http');
const queryString = require('query-string');
const DefaultLocale = require('../../');
const localeConfig = require('./config/custom')(__dirname);
const RS = 'rs'; // resource field
const LN = 'ln'; // language field
/*
* Query example
* http://localhost:3000/?rs=hel... |
(function (global) {
var Template = function (str) {
this.template = str || '';
Object.defineProperties( this, {
modifier: {
writable: true,
value: this._modifier
}
});
return this;
}
Object.defineProperties( Template.prototype, {
_regex: {
writable: fal... |
'use strict';
describe('Controller: PollioCtrl', function () {
// load the controller's module
beforeEach(module('pollioApp'));
var PollioCtrl, scope;
// Initialize the controller and a mock scope
beforeEach(inject(function ($controller, $rootScope) {
scope = $rootScope.$new();
PollioCtrl = $contr... |
console.log('Phantom started');
var system = require('system');
var page = require('webpage').create();
var args = system.args;
var url = args[1];
var width = args[2];
var height = args[3];
var format = args.length > 4 ? args[4] : 'mp4';
var targetFrame = args.length > 5 ? parseInt(args[5]) + 2 : 11;
var framerate = ... |
version https://git-lfs.github.com/spec/v1
oid sha256:9083011db2f9aae55d1824530a7eccf522becc6ca224accc8f294e383ffddad5
size 63585
|
/**
* Created by Administrator on 14-7-30.
*/
goog.provide("net.DecoratedSocketController");
goog.require('bok.EventDispatcher');
BOK.inherits(DecoratedSocketController, EventDispatcher);
/**
* @constructor
* @param {DecoratedSocketController=} controller (optional)
* */
function DecoratedSocketController(cont... |
// 'Arguments', 'Function', 'String', 'Number', 'Date', 'RegExp', 'Error'
function is(type, obj) {
return Object.prototype.toString.call(obj) === '[object ' + type + ']';
}
var template = function(text, settings) {
var escaper = /\\|'|\r|\n|\u2028|\u2029/g;
var escapeChar = function(match) {
return... |
import React from "react";
import {Icon, Message} from "semantic-ui-react";
import {connect} from "react-redux";
import {hasDuplicatedItems} from "../../selectors";
let DuplicatesNotification = ({visible}) => {
return (
<Message
icon
warning
hidden={!visible}>
... |
!function(t){t.Model.prototype.save=function(){var e=t.Model.prototype.save;return function(){if("function"==typeof this.before){var t=this.before.call(this,arguments);if(t===!0)return}return e.apply(this,arguments)}}()}(Backbone); |
import each from 'lodash/each';
/**
* The container that holds all the stores.
*
* @type {Object}
*/
const container = {};
/**
* Register a new store.
*
* @param {String} key
* @param {Object} store
*
* @return {void}
*/
export function register(key, store) {
if (typeof store === 'function') {
contain... |
/*
* grunt-inline-css
* https://github.com/jgallen23/grunt-inline-css
*
* Copyright (c) 2013 Greg Allen
* Licensed under the MIT license.
*/
'use strict';
module.exports = function(grunt) {
// Please see the Grunt documentation for more information regarding task
// creation: http://gruntjs.com/creating-ta... |
function panic(message) {
throw new Error(message);
}
function clone(object) {
var c = {};
var p;
if (typeof object !== "object") {
return object;
}
for (p in object) {
if (object.hasOwnProperty(p)) {
c[p] = clone(object[p]);
}
}
return c;
}
functio... |
var Encore = require('@symfony/webpack-encore');
Encore
.setOutputPath('app_build/')
.setPublicPath('.')
.setManifestKeyPrefix('app_build')
.addEntry('app', './js/app.js')
.addStyleEntry('app_styles', [
'./node_modules/bootstrap/dist/css/bootstrap.min.css',
'./node_modules/nouislide... |
export default class Display {
constructor(displayDomContainer) {
let pixelWidth = displayDomContainer.width / 64;
let pixelHeight = displayDomContainer.height / 32;
this.states = this.clearStates();
this.resolution = { width: 64, height: 32 };
this.pixel = { width: pixelWidth, height: pixelHeigh... |
import { Provider } from 'react-redux'
import React, { PropTypes } from 'react'
const containerName = process.env.HP_CONTAINER
const Container = require(`./../containers/${containerName}`).default
const params = {}
const HomepageRoot = ({ store }) => (
<Provider store={store}>
<Container params={params} />
</Prov... |
$(function() {
$('#recherche_espece').typeahead({ source: noms });
}); |
// ==UserScript==
// @name DS16
// @namespace https://github.com/psuet/usefulScripts/
// @version 0.23
// @description MathJAX FTW
// @author Paul Sütterlin
// @match https://www2.math.rwth-aachen.de/*/exquery.html
// @updateURL https://raw.githubusercontent.com/psuet/usefulScripts/mas... |
// SiteMap.js (c) 2012 Loren West and other contributors
// May be freely distributed under the MIT license.
// For further details and documentation:
// http://lorenwest.github.com/node_monitor
(function(root){
// Module loading - this runs server-side only
var Monitor = root.Monitor || require('monitor'),
... |
version https://git-lfs.github.com/spec/v1
oid sha256:ff83bdbae5d0053ad550d94349ea7556bc6ccfcb4ad893480fa6c4eb2a6d018b
size 12210
|
tabular.Search = function(element, options, myOptions) {
this._element = element;
this._options = options;
this._myOptions = myOptions || {};
this._init();
};
tabular.Search.prototype = {
destroy: function() {
this._input.remove();
this._form.remove();
this._element.off('view:header.tabularSe... |
module.exports = {
"Stream load": function (assert) {
var done = assert.async();
createStreamWithDisplay(function (data) {
assert.equal(data.length, 6);
done();
}).load("test.csv", { format: "csv" });
},
"Stream load and transform": function (assert) {
var done = assert.async();
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.