code
stringlengths
2
1.05M
var webpack = require( 'webpack' ), entry = __dirname + "/src/middle.src.js"; module.exports = { entry: { "middle": entry, "middle.min": entry, }, devtool: 'source-map', output: { path: __dirname + '/dist', filename: '[name].js', library: 'Middle', libraryTarget: 'umd', umdNamedDefine: true }, plu...
export const GET_LATEST_RATES_REQUESTED = 'GET_LATEST_RATES_REQUESTED'; export const GET_LATEST_RATES_SUCCEDED = 'GET_LATEST_RATES_SUCCEDED'; export const GET_LATEST_RATES_FAILED = 'GET_LATEST_RATES_FAILED'; export const ADD_BASE = 'ADD_BASE'; export const UPDATE_BASE_VALUE = 'UPDATE_BASE_VALUE'; export const ADD_RAT...
/** * load.js * author: borysn * license: MIT */ const execSync = require('child_process').execSync; const chalk = require('chalk'); const path = require('path'); const fsUtils = require('./fsUtils'); const exceptions = require('./exceptions'); const i3LmCmd = require('./i3LmCmd'); // load function load() { i3Lm...
/// <reference path="../../../../typings/express/express.d.ts"/> var Path = require("path"); var Lodash = require('lodash'); /*** * Yog中间件配置 * */ module.exports.http = { /*************************************************************************** * * Middleware配置 * * 用于管理加载哪些中间件,以及这些中间件的加...
/* * Cubitoo Typography (1.1) * by Paweł Komarnicki (http://cubitoo.com) * pawel@cubitoo.com * * Copyright (c) Paweł Komarnicki (http://cubitoo.com) * Licensed under the MIT license (see MIT-LICENSE.txt) * * NOTE: This script requires jQuery to work. Download jQuery at www.jquery.com */ (function($) { $.f...
import { c } from 'ttag'; import { updateAutoWildcardSearch } from '@proton/shared/lib/api/mailSettings'; import { Row, Label, Info, Toggle, Field } from '../../components'; import { useMailSettings, useEventManager, useLoading, useApi } from '../../hooks'; const SearchSection = () => { const api = useApi(); c...
var Utils={},stringify; Utils.hexTable = new Array(256); for (var i = 0; i < 256; ++i) { Utils.hexTable[i] = '%' + ((i < 16 ? '0' : '') + i.toString(16)).toUpperCase(); } var internals = { delimiter: '&', arrayPrefixGenerators: { brackets: function (prefix, key)...
export default () => Promise.resolve(window.Plotly || import(/* webpackChunkName: "plotlyjs" */ 'plotly.js-dist-min').then(({ default: Plotly }) => { window.Plotly = Plotly; return Plotly; }));
var _ = require('lodash'); //Constructor function Trip(dateStart, dateEnd, vehicleName, startAddress, startMapImageUrl, startTemperature, startWeatherConditions, stats, alerts, endAddress, endMapImageUrl, endTemperature, endWeatherConditions) { this.dateStart = dateStart || ''; this.dateEnd = dateE...
/* * jQuery.ajaxQueue - A queue for ajax requests * * (c) 2011 Corey Frang * Dual licensed under the MIT and GPL licenses. * * Requires jQuery 1.5+ */ (function ($) { // jQuery on an empty object, we are going to use this as our Queue var ajaxQueue = $({}); $.ajaxQueue = function (ajaxOpts) { var console, ...
var GoogleStrategy = require('passport-google-oauth').OAuth2Strategy; var config = require('../config').auth.google; var db = require('../storage/db'); function findUser(email, cb) { db.getUserByEmail(email, cb); } module.exports = function(passport) { // used to serialize the user for the session passp...
import React from 'react'; import Button from 'material-ui/Button'; import Snackbar from 'material-ui/Snackbar'; import Fade from 'material-ui/transitions/Fade'; class FadeSnackbar extends React.Component { state = { open: false, }; handleClick = () => { this.setState({ open: true }); }; handleClos...
define(['global/session', 'services/errorhandler', 'services/config', 'services/logger', 'durandal/system'], function (session, errorhandler, config, logger, system) { var unitofwork = session.unitofwork(), units = ko.observableArray(), selectedDepartmentId = ko.observable(), ...
accountService.$inject = ['$http', 'apiUrl', '$window']; export default function accountService($http, apiUrl, $window) { return { // specific Company getCompany(companyId) { return $http .get(`${apiUrl}/companies/${companyId}`) .then(r => r.data); }, // get company by user ID ...
const GameObject = require('../../gamelib/GameObject.js'); const FSM = require('../../gamelib/components/FSM.js'); const Projectile = require('../../gamelib/components/Projectile.js'); const FLY_TIME = 5; const fsm = { fly: { onEnter: function() { this.destroyTime = FLY_TIME; }, onUpdate: functio...
var express = require('express.io'); var expressPath = require('express-path'); var mongoose = require('mongoose'); var path = require('path'); var stylus = require('stylus'); var nib = require('nib'); var favicon = require('serve-favicon'); var logger = require('morgan'); var cookieParser = require('cookie-parser'); v...
/** * Created by Gebruiker on 19-9-2015. */ 'use strict'; describe ('Homepage Test', function () { beforeEach (module('PVapp')); it ('should have tests', function (){ expect(true).toBe(true); }); });
var _ = require('underscore')._; var Redobl = require('./redobl').Redobl; var sys = require('sys'); var List = exports.List = function () { //sys.log("In List constructor..."); } Redobl.addClass('list', List); List.define = function(name, config, proto) { // The name argument is optional. if (typeof name !== ...
import getElement from './-get-element'; import fireEvent from './fire-event'; import { __focus__ } from './focus'; import settled from '../settled'; import isFocusable from './-is-focusable'; import { nextTickPromise } from '../-utils'; import isFormControl from './-is-form-control'; /** @private @param {Element}...
'use strict'; var _ = require('lodash'); var Onion = require('lib-onion'); var NumberTypeHandler = function(opts) { var chance = opts.chance; var debug = opts.debug; var onion = new Onion('number'); var Min = function(tests, chanceParams, next) { var minimum = _.find(tests, { name...
function validateTrackFields (fields: Object, actionType: string) { if (typeof actionType !== 'string' && !fields.event) { return new Error('missing event field for EventTypes.track') } return null } function getTrackProperties (fields: Object) { if (!fields.properties) return [ 'event', 'options' ] re...
const SDK = require('directus-sdk-javascript'); const config = require('../config/config'); function getDirectusClient() { return new SDK( config.directusApiKey, config.directusApiUrl, 1.1); } module.exports = { getDirectusClient, };
/** * Autocompletion using Ajax * * @version 1.0 * @author wolxXx * @package Autocomplete */ /** * a single autocomplete element */ var AutocompleteElement = new Class({ initialize: function(value, target){ var that = this; that.value = value; that.element = new Element('a'); that.element.set('text',...
'use strict'; module.exports = function(value, ends){ return { v : value, e : ends, childs : { } }; };
'use strict'; angular.module('analytics-app.dashboard.reporting.sales.overview', [ 'ui.router', 'ui.bootstrap', 'chart.js' ]) .run(['$rootScope', function($scope) { $scope.labels = ["January", "February", "March", "April"]; $scope.series = ['This year']; $scope.data = [[34000, 40000, 38000, 41000, 42000]]; ...
angular.module('fellowship.modules.api.services') .service('ApiService', function($http, $q){ var service = {}; var urlBase = 'http://uvkkc35ecaa7.vinifig.koding.io:8080/api' var isMaster = []; var isProjectMaster = []; var isProjectLeader = []; var isProjectMember = []; var veri...
/** * ChatRoom.js * * @description :: TODO: You might write a short summary of how this model works and what it represents here. * @docs :: http://sailsjs.org/#!documentation/models */ module.exports = { schema: true, attributes: { title : { type: 'string', required: true }, slug ...
exports.check = function (markoCompiler, expect) { var lookup = markoCompiler.buildTaglibLookup(__dirname); // console.log('LOOKUP: ', Object.keys(lookup.attributes)); var noupdateAttr = lookup.getAttribute("div", "no-update"); expect(noupdateAttr != null).to.equal(true); expect(noupdateAttr.type).to.equal("f...
var config = { DataUrl: 'https://vsemmirom.i-free.ru/getter.php', DataRequestTimeout: 2500, DataRequestPeriod: 3500, VizEngineTimeout: 1000, // DIP //Proxy: 'http://dip-proxy.ed.dip.1tv:3128', //VizEngineIp: '172.16.11.114', // DUT Proxy: 'http://proxy.1tv.ru:8080', VizEngineIp: ...
// 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...
/* Endless: A bidirectional, React infinite scroll component. Based on ReactList (https://github.com/orgsync/react-list) */ /* jshint browser: true */ /* global define, module */ /* jshint -W116 */ // Don't warn about single-line if's. const ReactDOM = require('react-dom'); (function(root, factory) { if (typeof d...
(function (global, factory) { if (typeof define === "function" && define.amd) { define(['module', 'exports'], factory); } else if (typeof exports !== "undefined") { factory(module, exports); } else { var mod = { exports: {} }; factory(mod, mod.exports); global.KangaxProvider = mod.ex...
var Issue = (function () { function Issue () { init.call(this); }; function init (name, time, u) { this.name = name || ''; this.time = time || null; this.uncertainty = u || null; this.issues = []; this.form = null; } function addIssue (issue, hidden) { issue.parent = this; if(hidden){ this.i...
const {createError} = require('micro') const TOKEN_KEY = 'hcag-deployment-token' module.exports = req => { if (req.headers[TOKEN_KEY] !== process.env.HCAG_DEPLOYMENT_TOKEN) { throw createError(403, 'Forbidden') } }
/** * Wrapper for SVGGeometryElement interface * * It can wrap SVGElement elements * * If svgDOMNode is wrapped by Vector.Geometry's super class then * it removes that wrapper and returns a new Vector.Geometry wrapper. * To get a appropriate wrapper please use Vector.wrap() method. * * @type {Vector.Geometry}...
$(document).on('click', "#newgame_button", function() { return validate_create(); }); $(document).on('click', "#restart_button", function() { start_game(); }); // initializes the game board function create_game(columns, rows, turn) { // inspired by http://www.youtube.com/watch?v=qaGd65opzgo // and (modified from) h...
var stat_refresh_interval = 10000; var stat_refresh_fails = 0; /* be nice to graphite */ var graph_refresh_interval = 60000; var graph_refresh_fails = 0; var interval_id; $('a#memgraph-link').click(function() { $.scrollTo('#memgraph', { duration: 1, offset: { left: 0, top: ...
_.mixin({ /*jshint -W100*/ /** * utf8 encode a string * * @function module:undermore.utf8_encode * @link http://monsur.hossa.in/2012/07/20/utf-8-in-javascript.html * @param {string} str The string to encode * @return {string} * @example * _.utf8_encode('asdf') === 'asdf'...
import React from 'react'; const DummyIcon = props => <svg {...props} />; module.exports = { Close: DummyIcon, Favorite: DummyIcon, KeyboardArrowRight: DummyIcon, KeyboardDown: DummyIcon, Link: DummyIcon, Search: DummyIcon, };
var util = require('util'); /* * Encodes binary data as standard base64 with padding. * * If the input is a string, it encodes it as utf8 before converting to base64. This method will * throw if it is passed the wr * * @param input {String | Buffer} the input to encode. * @return {String} the base64 encoded ve...
modules.define('app-kernel__config', ['objects'], function (provide, objects, config) { "use strict"; provide(objects.extend({ port: 3000, staticHost: 'localhost:8080' }, config)); });
"use strict"; let stars = []; window.addEventListener("load", () => { stars = populateStars(87) // console.log(stars) }, false); let animate = (con, currentTime) => { con.save(); stars.map((star) => star.draw(con, currentTime)) con.restore(); } let populateStars = (numStars) => { let arr = Array.apply(nu...
/** * This file contains some default function */ // // decrypt helper function function decryptCharcode(n,start,end,offset) { n = n + offset; if (offset > 0 && n > end) { n = start + (n - end - 1); } else if (offset < 0 && n < start) { n = end - (start - n - 1); } return String.fromCharCode(n); } // // decr...
const { assert, skip, test, module: describe, only } = require('qunit'); const { GPU } = require('../../../../../../src'); describe('feature: to-string unsigned precision returns Texture'); function testReturn(mode, context, canvas) { const gpu = new GPU({ mode }); const originalKernel = gpu.createKernel(function...
'use strict'; describe('Select directive', function() { var element, scope; beforeEach( module('jsLib.widgets') ); // beforeEach( module('jsWidgets.scrollList') ); beforeEach( module('jsLib.restModel') ); // load the templates beforeEach( module( 'test/js-widgets/simple-scroll-list.html') ); befo...
'use strict'; (function() { // Cores Controller Spec describe('Cores Controller Tests', function() { // Initialize global variables var CoresController, scope, $httpBackend, $stateParams, $location; // The $resource service augments the response object with methods for updating and deleting the resour...
import 'whatwg-fetch' import serialize from './serialize' export const baseURL = process.env.NODE_ENV === 'production' ? 'http://localhost:5000/' : 'http://localhost:5000/' const headers = new Headers({ "Content-Type": "application/x-www-form-urlencoded" }) const ajax = (args) => ( Promise.resolve( fetch(`${...
var Op = require('./../models/operationModel'); module.exports.create = function (req, res) { var opName = req.params.opName; var op = new Op(); op.name = opName; op.save(function (err, result) { res.json(result); }); }; module.exports.list = function (req, res) { Op.find...
import React from 'react'; import {Observable, Subject} from 'rxjs'; export class Counter extends React.Component { constructor() { super(); this.state = { count: 0 }; // Obvs to represent increase, decrease event streams this.decrease$ = new Subject(); this.increase$ = new Subject();...
'use strict'; module.exports = { app: { title: 'Civiception', description: 'Full-Stack JavaScript with MongoDB, Express, AngularJS, and Node.js', keywords: 'MongoDB, Express, AngularJS, Node.js' }, port: process.env.PORT || 3000, templateEngine: 'swig', sessionSecret: 'MEAN', sessionCollection: 'sessions',...
import { Meteor } from 'meteor/meteor'; import { Users } from '../../app/models'; Meteor.publish('activeUsers', function() { if (!this.userId) { return this.ready(); } return Users.findUsersNotOffline({ fields: { username: 1, name: 1, status: 1, utcOffset: 1, statusText: 1, }, }); });
/*!--------------------------------*\ 3-Jekyll Theme @author Peiwen Lu (P233) https://github.com/P233/3-Jekyll \*---------------------------------*/ // Detect window size, if less than 1280px add class 'mobile' to sidebar therefore it will be auto hide when trigger the pjax request in small screen devices. i...
app.controller('UsersPasswordCtrl', ['$state', '$scope', 'users', '$timeout', 'SweetAlert', 'toaster', '$http', function ($state, $scope, users, $timeout, SweetAlert, toaster) { //Init input addForm variable //create users $scope.process = false; if ($scope.dataUser.level == 0 ) { $state.go("ap...
var domain = $("#domain").val(); $("#sign-in-form").submit(function(e) { e.preventDefault(); $.getJSON(domain + "/users/sign_in?callback=?", { user: {email: $("#sign-in-form input#email-input").val(), password: $("#sign-in-form input#password-input").val()} }, function(json) { if(json.success) { $.get("/u...
var Helpers = require('./Helpers'); exports.build = function (Dialect, where, opts) { if (where.length === 0) { return []; } var query = [], subquery; for (var i = 0; i < where.length; i++) { subquery = buildOrGroup(Dialect, where[i], opts); if (subquery !== false) { query.push(subquery); ...
'use strict'; describe('Controller: AdminContentCtrl', function () { // load the controller's module beforeEach(module('nboApp')); var AdminContentCtrl, scope; // Initialize the controller and a mock scope beforeEach(inject(function ($controller, $rootScope) { scope = $rootScope.$new(); AdminC...
import Table from '../components/custom/table'; import Divider from '../components/custom/divider'; import Photo from '../components/custom/photo'; import Rich from '../components/custom/rich'; import Document from '../components/custom/document'; /* * BlockRenderer is responsible for rendering custom block types. *...
/* * crappy helpers. * TODO Refactor - this is a bag of separate functions */ var _ = require('underscore'); exports.stringify = function (obj) { var nobj = _(obj).clone(); nobj = objToStringJS(nobj); var str = JSON.stringify(nobj); str = str.replace(/"__js:([^"]*)"/g, '$1'); return str; }; ex...
import {Transform} from 'stream' import {decoder} from './utils' /** * @description Splitter decodes incoming buffer to utf8 string and splits the * chunks on a given character. */ export default class Splitter extends Transform { /** * * @param {string} char - split character * @param {Object} opts - N...
/* * urban-airship-push * https://github.com/BrightSnowman/urban-airship-push * * Copyright (c) 2013 Alexander Kohout * Licensed under the MIT license. */ 'use strict'; var HTTP_RESPONSE_CODES = require('./../http-response-codes'); var REST_ENDPOINTS = { SCHEDULED_PUSH: '/api/schedules' }; var urbanAirship...
export default function promiseMiddleware() { return ({ dispatch, getState }) => ( (next) => (action) => { if (typeof action === 'function') { return action(dispatch, getState); } const { promise, types, ...rest } = action; if (!promise) { return next(action); } ...
console.log(person.name);
/* eslint-env node, mocha */ import {expect} from 'chai' import treePrices from '../src/treePrices.js' describe('treePrices', () => { it('updates the prices for a tree', () => { let recipeTree = { id: 1, usedQuantity: 1, components: [ {id: 2, usedQuantity: 1}, {id: 3, usedQuanti...
var breadcrumbs=[['-1',"",""],['2',"SOLUTION-WIDE PROPERTIES Reference","topic_0000000000000C16.html"],['2228',"Tlece.Recruitment.Models.RecruitmentHistory Namespace","topic_0000000000000774.html"],['2238',"RecruitmentHistoryDetailModel Class","topic_0000000000000780.html"],['2239',"Properties","topic_0000000000000780_...
describe("Player",function(){var a,b,c=require("../../lib/Player"),d=require("../../lib/Song");beforeEach(function(){a=new c,b=new d}),it("should be able to play a Song",function(){a.play(b),expect(a.currentlyPlayingSong).toEqual(b),expect(a).toBePlaying(b)}),describe("when song has been paused",function(){beforeEach(f...
import backups from './backups'; import databases from './databases'; import logs from './logs'; import modalController from 'utility/modal'; import userUtil from 'utility/user'; import errorHandler from 'error/error_handler'; import * as userActionsCreators from 'actions/user'; import * as dataActionsCreators from 'ac...
var CACHE_VERSION = 'v1'; var CACHE_NAME = CACHE_VERSION + ':sw-cache-'; function onInstall(event) { console.log('[Serviceworker]', "Rails Service Worker Installing!", event); event.waitUntil( caches.open(CACHE_NAME).then(function prefill(cache) { return cache.addAll([ // make sure serviceworker...
define(["common"], function(common) { common.log("Defining a"); return { a_main: function() { common.log("In a_main, Waiting for 5 seconds"); setTimeout(function() { common.log("Out a_main"); }, 5000); } } });
/*global $:false */ 'use strict'; function Carousel(container) { this.$container = container; } Carousel.prototype.buildCarousel = function() { var $slideContainer = $('<div />', {'class' : 'slide-container'}), $slides = this.$container.find('.slide'), $arrow = $('<div />', {'class' : 'nav-arrow'}), currentS...
'use strict'; var gulp = require('gulp'); var mocha = require('gulp-mocha'); var istanbul = require('gulp-istanbul'); var eslint = require('gulp-eslint'); gulp.task('coverage', function() { return gulp.src(['index.js', 'lib/*.js']) .pipe(istanbul({includeUntested: true})) .pipe(istanbul.hookRequire()); }); ...
import * as Fathom from 'fathom-client'; function toggleSchemaNames() { const xrm = window.__GOTDIBBS_TOOLBOX__.context.Xrm; xrm.Page.ui.controls.forEach(function (c, i) { if (!c.__label) { c.__label = c.getLabel(); c.setLabel(c.getName()); } else { c.setLab...
import React from 'react'; import PropTypes from 'prop-types'; import Button from '~/Button'; import styles from './comment.scss'; /** * Comment component */ const Comment = ({ comment, like, unlike }) => ( <article className={styles.comment}> <p>{comment.text}</p> { comment.liked ? <Button t...
var CandlestickFinder = require('../../lib/candlestick/CandlestickFinder').default; var assert = require('assert'); var input = { open: [30.10,30.18,30.15,29.15,28.35,29.19,28.83,28.13,28.17,28.35,28.34], high: [30.20,30.28,30.45,29.35,29.35,29.29,28.83,28.73,28.67,28.85,28.64], low: [29.41,29.32,29.96,28.74,2...
(function () { 'use strict'; angular.module('gg.promise-button') .directive('promiseButton', function ($log, $timeout, PromiseButton, $sce) { return { restrict: 'A', transclude: true, template: '<span class="promise-button-container">' + '<span class="original-content" ng-...
const _ = require('lodash') const errors = require('../../lib/errors') const userService = require('../../service/user') module.exports = async (ctx) => { let filter = ['username', 'nickname'] let data = _.pick(ctx.request.body, filter) // 检查用户名 let user = await userService.getByUserNameAsync(data.username) ...
/* --- Day 13: Knights of the Dinner Table --- In years past, the holiday feast with your family hasn't gone so well. Not everyone gets along! This year, you resolve, will be different. You're going to find the optimal seating arrangement and avoid all those awkward conversations. You start by writing up a list of ev...
/** * Created by mag94 on 12/1/15. */ var selectedBibsKey = "selectedBibs"; // defined in _header.html.erb var selectedRaceKey = "selectedRace"; var selected_racers = []; var selected_races = { "routeid": "", "points": [] }; var racer_markers = []; // array of markers that are displayed on map var checkboxes = [...
var fs = require("fs"); var path = require("path"); var jsext = require("jsext"); var log = require("jsext").Log; module.exports = DNA; function DNA (file, dir) { var self = this; if(!file) throw new Error("DNA : missing params"); self.file = file; self.dir = dir; self.reload(); } DNA.prototype....
import PropTypes from 'prop-types' import React from 'react' import styles from 'part:@lyra/components/labels/default-style' export default class DefaultLabel extends React.PureComponent { static propTypes = { className: PropTypes.string, children: PropTypes.node, level: PropTypes.number } render() {...
function solve(args) { var num = +args[0]; switch (num % 10) { case 0: return 'zero'; case 1: return 'one'; case 2: return 'two'; case 3: return 'three'; case 4: return 'four'; case 5: return ...
/** * This file is generated by Sencha Cmd and should NOT be edited. It is * provided to support globbing requires, custom xtypes, and other * metadata-driven class system features */ // @tag core // @define Ext.Boot // @define Ext // here, the extra check for window['Ext'] is needed for use with cmd-test // ...
/* * grunt-bower-vinstall * https://github.com/slhenty/grunt-bower-vinstall * * Copyright (c) 2014 cognivator * Licensed under the MIT license. */ 'use strict'; module.exports = function (grunt) { // Project configuration. grunt.initConfig({ jshint: { all: [ 'Gruntfi...
console.log('Learn You Node tutorial code')
// Generated by LiveScript 1.2.0 (function(){ var Debugger, util, ApplyContext, toString$ = {}.toString; Debugger = require('../util').Debugger; util = require('util'); module.exports = ApplyContext = (function(){ ApplyContext.displayName = 'ApplyContext'; var prototype = ApplyContext.prototype, constru...
'use strict'; const { DateTime } = require('luxon'); const db = require('../database'); const socket = require('./socket'); class Stats { constructor() {} get data() { return { feed: { list: db.stats.get('feed.list').value() }, charts: { follows: db.stats.get('follows').va...
// JavaScript Document function runReg() { $('#ajax-panel').empty(); $('#ajax-panel').html('<div class="loading"><b>Loading... </b><img src="/images/loading.gif" alt="Loading..." /></div>'); var _salt = "swagger"; var saltGet = $.ajax( { type: "GET", url: "/getSalt.php", data: "&d=y", asy...
/* SpeakersController: .speakers */ (function(angular) { 'use strict'; angular .module('com.david-rodenas.gm.pages.speakers') .controller('SpeakersController', SpeakersController); SpeakersController.$inject = ['speakers']; function SpeakersController ( speakers ) { var self; self = this; self.sp...
{ if (this.props.x === 317) { return React.createElement( "div", { className: "_4lg0 _4h2m", style: { height: 40, width: 721, left: 0 } }, undefined, React.createElement(TransitionCell142, { x: 316 }) ); } i...
/** * @param {string} s * @return {string} */ var reverseVowels = function (s) { var set = { 'a': 1, 'e': 1, 'i': 1, 'o': 1, 'u': 1, 'A': 1, 'E': 1, 'I': 1, 'O': 1, 'U': 1 }; var strArray = s.split(''); var i = 0; var j = strArray.length - 1; var temp; while (i...
import requireDir from "require-dir" /** * Load Gulp files from a subdirectory recursively */ requireDir('./gulp', {recurse: true});
module.exports = [ 'Id', 'status', 'ErrorMessage', 'ASIN', 'Title', 'ListPrice', 'CurrencyCode', 'ProductCategoryId', 'Rank', 'timestamp' ]
/*globals describe, it, beforeEach */ 'use strict'; var assert = require("assert"); var sinon = require("sinon"); describe('Date', function () { describe('Date.now()', function () { it('returns date in milliseconds', function () { var now = Date.now(); sinon.stub(Date, 'now', function () { ...
/** * IE and Opera leave an empty paragraph in the contentEditable element after clearing it * * @param {Object} contentEditableElement The contentEditable element to observe for clearing events * @exaple * wysihtml5.quirks.ensureProperClearing(myContentEditableElement); */ wysihtml5.quirks.ensureProperClearin...
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; /* Tabulator v4.5.1 (c) Oliver Folkerd */ var Aj...
BasicGame.MainMenu = function (game) { this.music = null; this.playButton = null; }; BasicGame.MainMenu.prototype = { create: function () { // We've already preloaded our assets, so let's kick right into the Main Menu itself. // Here all we're doing is playing some music and adding a p...
define([ 'jquery', 'underscore', 'backbone', 'config', 'utils', ], function($, _, Backbone, config, utils) { "use strict"; var GraphViewBase = Backbone.View.extend({ className: 'graph', initialize: function(options) { var self = this; this.renderAxes = options.renderAxes; if ...
/*! * chartjs-plugin-annotation v1.2.2 * https://www.chartjs.org/chartjs-plugin-annotation/index * (c) 2021 chartjs-plugin-annotation Contributors * Released under the MIT License */ import { Element, defaults, Chart, Animations } from 'chart.js'; import { defined, distanceBetweenPoints, callback, isFinite, valueOrD...
'use strict'; /** * @author liyixin5 * @date 2015-11-5 * @desc 喵酱 */
import React from 'react'; class Connexion extends React.Component { goToApp = event => { event.preventDefault(); // On récupère le pseudo const pseudo = this.boxInput.value; // On change d'url this.context.router.transitionTo(`/box/${pseudo}`); } render() { return ( <div className="connexionBox"> ...
'use strict' // Template version: 1.2.8 // see http://vuejs-templates.github.io/webpack for documentation. const path = require('path') module.exports = { dev: { // Paths assetsSubDirectory: 'static', assetsPublicPath: '/', proxyTable: {}, // Various Dev Server settings host: 'localhost', ...