code
stringlengths
2
1.05M
class A {} module.exports = new A();
function append(msg) { $('body').append('<p>' + msg + '</p>'); } var firstBus = Drekkar.get("First"); var secondBus = Drekkar.get("Second"); secondBus.register("FromMain", function(name) { append(name); secondBus.post("FromJSForMain"); }); secondBus.register("FromMainAfterFromJS", function(name) { ap...
'use strict'; var expect = require('chai').expect; var utils = require('../../lib/utils'); describe('utils', function() { describe('splitLines', function() { it('should split on LF', function() { expect(utils.splitLines('one\ntwo')).eql(['one', 'two']); }); it('should split on CR', function() { ...
'use strict'; exports.__esModule = true; function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; } function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError('Cannot call a class as a function'); } } var _jquery = require('...
(function($,sr){ // debouncing function from John Hann // http://unscriptable.com/index.php/2009/03/20/debouncing-javascript-methods/ var debounce = function (func, threshold, execAsap) { var timeout; return function debounced () { var obj = this, args = arguments; function delayed...
const webpackConfig = require('./webpack.config') module.exports = function (config) { config.set({ basePath: '', frameworks: ['jasmine'], files: ['tests/*.spec.js'], webpack: { module: webpackConfig.module }, webpackServer: { noInfo: true }, exclude: [], preprocessors: { 'tests/*.spec.js...
require('dotenv-extended').load({ path: '../.env' }); var builder = require('botbuilder'); var restify = require('restify'); var LuisActions = require('../../core'); var SampleActions = require('../all'); var LuisModelUrl = process.env.LUIS_MODEL_URL; var DefaultReplyHandler = function (session) { session.end...
import Vue from '../../utils/vue' import { mergeData } from 'vue-functional-data-merge' export const props = { id: { type: String, default: null }, tag: { type: String, default: 'div' }, tooltip: { type: Boolean, default: false }, forceShow: { type: Boolean, default: false...
'use strict'; var ngModule = require('vendor/utils').ngModule; var angular = require('vendor/angular'); // Declare app level module var app = angular.module('uFaber', [ ngModule('ui.router'), ngModule('ngMaterial'), ]); app.config(function($stateProvider, $urlRouterProvider) { $urlRouterProvider.otherwise('/'); ...
/* @flow */ let cachedResult = null; export default function supportsCaptureOption(): boolean { if (cachedResult === null) { let result = false; try { const opts = (Object:any).defineProperty({}, 'capture', { get() { result = true; return undefined; } }); ...
version https://git-lfs.github.com/spec/v1 oid sha256:2acdbe980ccc72215a8a5cd5a200147c0fe23a46d9562a69e539cba97bab8784 size 32116
'use strict'; angular.module('tinDev', ['ngAnimate', 'ngCookies', 'ngTouch', 'ngSanitize', 'firebase', 'ngResource', 'ui.router']) .config(function ($stateProvider, $urlRouterProvider) { $stateProvider .state('home', { url: '/', templateUrl: 'partials/main.html', controller: 'MainCt...
import { h } from 'omi'; import createSvgIcon from './utils/createSvgIcon'; export default createSvgIcon(h("path", { d: "M2 9c-.55 0-1 .45-1 1v10c0 1.1.9 2 2 2h14c1.11 0 2-.89 2-2H4c-.55 0-1-.45-1-1v-9c0-.55-.45-1-1-1zm16-4V3c0-1.1-.9-2-2-2h-4c-1.1 0-2 .9-2 2v2H7c-1.1 0-2 .9-2 2v9c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V7c0-...
import { isDefined } from '../checks/isDefined'; import { isNumber } from '../checks/isNumber'; /** * @hidden */ export function quadSpinorE2(s) { if (isDefined(s)) { var α = s.a; var β = s.b; if (isNumber(α) && isNumber(β)) { return α * α + β * β; } else { ...
(function() { /* ======== A Handy Little QUnit Reference ======== http://api.qunitjs.com/ Test methods: module(name, {[setup][ ,teardown]}) test(name, callback) expect(numberOfAssertions) stop(increment) start(decrement) Test assertions: ok(value, [message]) ...
import React from 'react'; import TextInputStyledComponents from "ps-react/TextInputStyledComponents"; /** Optional TextBox */ export default class ExampleOptional extends React.Component { render() { return ( <TextInputStyledComponents htmlId='example-optional' label='First Name' n...
(function () { 'use strict'; function collaborators(data) { function getCollaborators(projectId) { return data.get('api/projects/collaborators/' + projectId); } return { getCollaborators: getCollaborators } } angular.module('myApp.services') .factory('collaborators', ['data',...
window.injector = require('!!../../lib/loader?inject!./inject.san')
'use strict'; class SignupController { //start-non-standard user = {}; errors = {}; submitted = false; //end-non-standard constructor(Auth, $state) { this.Auth = Auth; this.$state = $state; } register(form) { this.submitted = true; if (form.$valid) { this.Auth.createUser({ ...
/** * Turn an object into an event emitter. Attaches methods `on`, `off`, * `emit`, and `list` * @param {Object} obj * @return {Object} Returns the original object, extended with emitter functions */ export default function emitter(obj) { var _callbacks = {}; obj.emit = function (event, data) { var callba...
import { module, test } from 'qunit'; import auth0 from 'auth0'; module('Unit | auth0 export'); test('auth0 exports', (assert) => { assert.ok(auth0, 'auth0 exports'); });
/** * The EachComponent allows to loop through the search results found with the InputComponent. * * @type {EachComponent} */ EasySearch.EachComponent = class EachComponent extends SingleIndexComponent { /** * Return the mongo cursor for the search. * * @returns {Mongo.Cursor} */ doc() { if (...
var gulp = require('gulp'); var browserSync = require('browser-sync').create(); // Static server gulp.task('browser-sync', function() { browserSync.init({ server: { baseDir: "./" } }); gulp.watch('*/*.js').on('change', browserSync.reload); gulp.watch('**/*.html').on('...
'use strict'; module.exports = function(app) { var users = require('../../app/controllers/users.server.controller'); var questionresponses = require('../../app/controllers/questionresponses.server.controller'); // Questionresponses Routes app.route('/questionresponses') .get(questionresponses.list) .post(user...
import Relation from './Relation.js' import AttributeBuilder from './AttributeBuilder.js' import AttributeRenderer from './AttributeRenderer.js' export default class RelationBuilder extends AttributeBuilder { /** * Contains logic for building Relation instance. */ constructor() { super(); ...
var fixtures = require('../../support/fixtures'), should = require('should'); describe('Bucket', function() { var Bucket; before(function(done) { fixtures.Bucket(function(model) { Bucket = model; done(); }); }); describe('.validate', function() { describe('invalid data', function...
import check from '../core/check'; import operation from '../model/operation'; import browserReleaseCompiler from './browserReleaseCompiler'; function compileBrowserOperation() { const thisOperation = operation.create({ id: 'compile-browser', logMessage: 'Compiling sources for browser' }); thisOperation.perform = ({...
import React from 'react'; import { createFragmentContainer, graphql, } from 'react-relay/compat'; import { Link } from 'react-router'; import N from '../../NoteTypes'; import DCRecording from '../Note/Thumbnail/DCRecording'; import BibleVerse from '../Note/Thumbnail/BibleVerse'; import FileNoteThumbnail from '../...
import R from 'ramda' import React from 'react' import { Text, View, TouchableWithoutFeedback, } from 'react-native' import moment from 'moment' import DatePicker from 'react-native-datepicker' import * as variable from '../../theme/ume-theme/variable' import toast from '../../component/toast/normal' i...
/** * Created by Administrator on 2016/3/14 0014. */ import $ from 'jquery' var defaults={ maxWidth:828, maxHeight:1472 }; function dataURItoBlob(dataURI) { // convert base64 to raw binary data held in a string var byteString ,mimestring if(dataURI.split(',')[0].indexOf('base64') !== -1 )...
#!/usr/bin/env node 'use strict'; var argv = require('minimist')(process.argv.slice(2)); var pkg = require('./package.json'); //node cli.js --help if (argv.help) { console.log([ pkg.description, '', 'Example', ' $ node-version', ' v0.10.28' ].join('\n')); } //node cli.js --version if (argv.version)...
var VERSION = "0.1.2"; module.exports = { version: { abbr: "v", flag: true, callback: function(){ return "quickly version " + VERSION; } }, key: { position: 0, help: "If supplied, change directory to the path that was mapped to this key" }, add: { abbr: "a", metavar: "KE...
'use strict'; import angular from 'angular'; /** * The Util service is for thin, globally reusable, utility functions */ export function UtilService($window, $httpParamSerializer) { 'ngInject'; var Util = { /** * Return a callback or noop function * * @param {Function|*} cb - a 'potential' ...
//comentario 1 linea /* comentarios mas lineas */ console.log('alguna cosa'); var objeto1={ nombre: 'unnombre', apellido: 'unapellido', fecha: new Date(), imprimir: function (){ console.log(this.nombre + ' '+ this.apellido); }, anio: function(){ return this.fecha.getFullYear(); ...
/** * Created by j_nad on 15/01/2016. */ var app = angular.module('SearchMovieService', []); app.factory('searchMovieService', ["$rootScope", "$cookies", "$http", "$location", "alertFactory", "loadingModalService", function ($rootScope, $cookies, $http, $location, alertFactory,loadingModalService) { var ...
module.exports = { description: "", ns: "react-material-ui", type: "ReactNode", dependencies: { npm: { "material-ui/svg-icons/navigation/fullscreen": require('material-ui/svg-icons/navigation/fullscreen') } }, name: "NavigationFullscreen", ports: { input: {}, output: { componen...
// Generated by BUCKLESCRIPT, PLEASE EDIT WITH CARE 'use strict'; var Curry = require("bs-platform/lib/js/curry.js"); var Belt_Array = require("bs-platform/lib/js/belt_Array.js"); var Mocha$BsMocha = require("bs-mocha/lib/js/src/Mocha.bs.js"); var Parser$AgdaMode = require("../../src/Parser.bs.js"); var Promise$BsMoch...
import React from 'react' export default function NoMatch () { return ( <div role="warning" className="o-warning"> <p>Can not find the site you are looking for.</p> </div> ) }
const create = require('./create') /** * Multiplies two vec3's * * @param {vec3} [out] - the receiving vector * @param {vec3} a - the first operand * @param {vec3} b - the second operand * @returns {vec3} out */ const multiply = (...params) => { let out let a let b if (params.length === 2) { out = c...
var fs = require("fs") var path = require("path") var http = require("http") // You would "npm install mobwrite" and use require("mobwrite") instead. var mobwrite = require("../../mobwrite") mob = mobwrite({ logger: {error: console.error}, // Set a custom document loader. This example just uses a hardcoded sent...
"use strict"; var args = process.argv; var PWD = args[1]; var npmArgs = args.slice(2); var program = require('commander'); var config = require("./config.json"); var songUtil = require("./lib/songUtil"); var version = require("./package.json").version; program.version(version) .option('-m, --mood [type]', 'What ki...
"use strict"; jest.mock('../atomInterface'); const { isLinterEslintAutofixEnabled, shouldUseEslint, addWarningNotification } = require('../atomInterface'); const warnAboutLinterEslintFixOnSave = require('./index'); test('it warns about not having eslint autofix on', () => { isLinterEslintAutofixEnabled.mock...
/** * 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. * * @emails react-core * @jest-environment node */ let React; let ReactNoop; let useState; let Suspense; let block; let readString...
import EventPost from 'flarum/forum/components/EventPost'; export default class DiscussionStickiedPost extends EventPost { icon() { return 'fas fa-thumbtack'; } descriptionKey() { return this.attrs.post.content().sticky ? 'flarum-sticky.forum.post_stream.discussion_stickied_text' : 'flarum-s...
var React = require('react'); export default class InputBox extends React.Component { handleChange(e) { const text = e.target.value; this.props.updateMarkdown(text); } render() { return ( <textarea rows="30" cols="70" id="inputBox" defaultValue={this.props.markdownText} onChange={this.handleCha...
module.exports = { "ports":{ "origin": 3001, "diff": 3002 }, "scenario_path": __dirname + "/test/scenarios/**/*.js", "reftest_list_path": __dirname + "/lib/reftest.list", "diff_branch": "master", "copy_dir": "/tmp/component-viewer-sample" };
webpackJsonp([0],{0:function(e,n){},5:function(e,n,a){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var t=a(1),o=(a.n(t),a(2)),c=(a.n(o),a(0)),i=(a.n(c),a(3)),r=(a.n(i),a(4));a.n(r);!function(){for(var e=document.getElementsByTagName("a"),n=0;n<e.length;n++)e[n].setAttribute("target","blank")}(),window....
// models a chat room, module.exports = function () { function makeMessage(nickname, message) { var newMessage = new Message(nickname, message); return newMessage; }; return { makeMessage: makeMessage } }; function Message(nickname, message){ this.nickname = nickname; this.message = message...
import { keyEvent } from 'ember-native-dom-helpers'; import { moduleForComponent, test } from 'ember-qunit'; import hbs from 'htmlbars-inline-precompile'; moduleForComponent('foo-bar', 'Integration | Component | foo bar', { integration: true }); test('it renders', async function(assert) { this.render(hbs`{{foo-ba...
// // InteractionController.js // Arboretum // // Created by Alexander Rulkens on 2014-02-12. // Copyright 2014 Studio Ludens. All rights reserved. // define(["jquery", "underscore", "trackballControls"], function( $, _, TrackballControls ){ //var trackballControls = new TrackballControls(); var Inte...
module.exports = { hexToBytes: function (hex) { let bytes = [] for (let c = 0; c < hex.length; c += 2) { bytes.push(parseInt(hex.substr(c, 2), 16)) } return bytes }, bytesToHex: function (bytes) { let hex = [] for (let i = 0; i < bytes.length; i++) { hex.push((bytes.charCode...
angular.module('paris1.user.style.editor',[ 'ngMaterial', 'ui.ace' ]);
/** * @author: renyanwei * @date: 2017-05-10 * @file: mip-tiantis-54kefu.js */ define(function (require) { var $ = require('zepto'); var customElement = require('customElement').create(); customElement.prototype.build = function () { var currentElement = this.element; var...
import React from 'react'; import { shallow } from 'enzyme'; import Section from './Section'; import { TONE } from '../private/tone'; import { LEVEL } from '../private/level'; const renderSection = props => shallow(<Section {...props}>Test content</Section>); describe('Section:', () => { describe('types:', () => ...
function createTypedArray (length) { var result = new Uint32Array(length); for (var i = length; i > 0; i--){ result[i - 1] = Math.floor(Math.random() * 10000) + Math.floor(Math.random() * 10000) + Math.floor(Math.random() * 10000) + Math.floor(Math.random() * 10000); } return result; }; functio...
module.exports = function(grunt) { grunt.initConfig({ pkg: grunt.file.readJSON('package.json'), sass: { dist: { files: { 'app/static/styles.css': 'app/static/styles.scss' } } }, cssmin: { css:{ src: 'a...
import Freezable from './freezable.js' import Pool from './pool.js' /** * A two-dimensional vector. */ class Vector2 extends Freezable { /** * Constructor. * Sets all components to zero. * @param {number?} x * @param {number?} y */ constructor(x = 0, y = 0) { super(); /** * The x component. * ...
/*! * UI development toolkit for HTML5 (OpenUI5) * (c) Copyright 2009-2017 SAP SE or an SAP affiliate company. * Licensed under the Apache License, Version 2.0 - see LICENSE.txt. */ sap.ui.define(['jquery.sap.global','sap/ui/core/Element','./library'],function(q,E,l){"use strict";var D=E.extend("sap.ui.unified.Date...
// @flow import type { ConfigFileSearch, BabelrcSearch, IgnoreList, IgnoreItem, PluginList, PluginItem, PluginTarget, ConfigApplicableTest, SourceMapsOption, SourceTypeOption, CompactOption, RootInputSourceMapOption, NestingPath, CallerMetadata, RootMode, } from "./options"; export type ...
'use strict'; module.exports = { Collator: require('./lib/Collator'), DateTimeFormat: require('./lib/DateTimeFormat'), NumberFormat: require('./lib/NumberFormat'), Translation: require('./lib/Translation') };
// Main 'use strict'; var $ = require("jquery"), _ = require("underscore"); var indexController = require("./controllers/index.js"); $(document).ready(function () { indexController.init(); });
export default function () { return { modal1_state: false, LoginModalState: false, ClickOutsideState: true, NavPaneIsOpen: false, }; }
/** * This module defines a collection of static general utility functions. * * @module util */ (function () { /** * Adds an event listener for each of the given events to each of the given elements. * * @param {Array.<HTMLElement>} elements The elements to add event listeners to. * @param {...
/** * Libs */ var React = require('react'); var classNames = require('classnames'); /** * TupiqHeader */ var TupiqHeader = React.createClass({ render: function(){ var logoContainerClassName = classNames({ 'tupiq__header__logo-container': true, 'loading': this.props.isBackgroundLoading, 'errore...
/** * @class Lightbox * @classdesc Lightbox service. * @memberOf bootstrapLightbox */ angular.module('bootstrapLightbox').provider('Lightbox', function () { /** * Template URL passed into `$modal.open()`. * @type {String} * @name templateUrl * @memberOf bootstrapLightbox.Lightbox */ ...
'use strict'; angular.module('primetables.utils.array', [ ]) .service("ArrayUtils", function () { this.setRecurringValue = function (array, startIndex, endIndex, increment, value) { validateParameters(); var currentPosition = startIndex; while(currentPosition <= endIn...
export { default } from 'ember-cli-lightning-design-system/components/slds-media/figure';
// CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: http://codemirror.net/LICENSE // TODO actually recognize syntax of TypeScript constructs (function(mod) { if (typeof exports == "object" && typeof module == "object") // CommonJS mod(require("../../lib/codemirror"))...
// KPU Affine Dependence Graph representation // An object representing the affine data dependencies // in the system of recurrence equations // // # Code /** @namespace */ var KPU = KPU || {}; KPU.DgVertex = KPU.DgVertex || function(name) { this.name = name; }; KPU.AffineDependenceGraph = KPU.Affin...
/*! * @w6s/query-string.js v1.2.1 * (c) 2019 Hejx * Released under the MIT License. * https://github.com/WorkPlusFE/workplus-query-string#readme */ var parse = function parse(str) { str = str || window.location.search; // Create an object with no prototype var set = Object.create(null); if (typeo...
import getChannelData from '../actions/getChannelData' import updateChannelData from '../actions/updateChannelData' export default [ getChannelData, { success: [updateChannelData], error: [({input}) => console.log('ERRRORzz', input)] } ]
<!--{ ids:[127], language:'JavaScript', type:'workshop', order: 3, name:'Primary Data Types', description:'A data type is a particular representation of information' } --> var number1 = 1; var string2 = "San Francisco 49ers"; var string3 = 'true'; var boolean4 = false; var number5 = 5.07; var string6 = "1048...
'use strict'; const _ = require('lodash'); /** * Call method. Actually it's just reference to {@link Hapi.Server.inject} wrapped into {@link Promise} * * @param {Hapi.Server} server * @param {Object} [config] * @return {Function} */ module.exports = function (server, config) { config = config || {}; /**...
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ______ ______ ______ __ __ __ ______ /\ == \ /\ __ \ /\__ _\ /\ \/ / /\ \ /\__ _\ \ \ __< \ \ \/\ \ \/_/\ \/ \ \ _"-. \ \ \ \/_/\ \/ \ \_____\ \ \_____\ \ \_...
let push = (outTransformArray, index, offset) => { outTransformArray[index] = offset[0]; outTransformArray[index + 1] = offset[1]; return index + 2; }; let pop = (index, lowerBound = 0) => { return Math.max(index - 2, Math.max(lowerBound, 0)); }; let merge = (out, transformA, transformB) => { out[0] = trans...
import React from 'react'; import { expect } from 'chai'; import { Surface, Area } from 'recharts'; import { mount, render } from 'enzyme'; describe('<Area />', () => { const data = [ { x: 10, y: 50, value: 100 }, { x: 50, y: 50, value: 100 }, { x: 90, y: 50, value: 100 }, { x: 130, y: 50, value: 100...
const html = require('bel') const lory = require('lory.js').lory const icon = require('./icon') module.exports = (props) => { const elem = html` <div onload=${handleLoad} class="slider js_slider"> <div class="frame js_frame"> <ul class="slides js_slides"> ${props.slides.map(s => html`<li ...
import { __ } from 'embark-i18n'; import { dappPath, toForwardSlashes, normalizePath } from 'embark-utils'; let chokidar = require('chokidar'); let path = require('path'); const DAPP_PIPELINE_CONFIG_FILE = 'pipeline.js'; const DAPP_WEBPACK_CONFIG_FILE = 'webpack.config.js'; const DAPP_BABEL_LOADER_OVERRIDES_CONFIG_FIL...
(function( stik ){ stik.$$manager = stik.manager(); stik.controller = function controller( controllerName, action, executionUnit ){ if ( typeof action === "string" ) { return stik.$$manager.addControllerWithAction( controllerName, action, executionUnit ); } else { return stik.$$ma...
/** * * ListPage selectors * */ import { createSelector } from 'reselect'; /** * Direct selector to the listPage state domain */ const selectListPageDomain = () => state => state.get('listPage'); /** * Default selector used by ListPage */ const makeSelectListPage = () => createSelector( selectListPageDomai...
var webpack = require('webpack'); var UglifyJsPlugin = webpack.optimize.UglifyJsPlugin; var path = require('path'); var env = require('yargs').argv.mode; var libraryName = 'huffman'; var plugins = [], outputFile; if (env === 'build') { plugins.push(new UglifyJsPlugin({ minimize: true })); outputFile = libraryNam...
var Queue = require('bull'); var async = require('async'); var config = require('../../lib/config'); var util = require('util'); var EventEmitter = require('events'); var redisHost = config.redis.host; var redisPort = config.redis.port; var reqQueueName = config.bull.requestQueue; var resQueueName = config.bull.respon...
/* speedy.js */ /*jshint loopfunc: true */ (function (w) { this.w = w; this.stats = null; this.container = null; var InlineStyles = { reset: 'font-size:12px;z-index:99999;text-align:left;font-family:Calibri,\'Lucida Grande\',Arial,sans-serif;text-shadow:none;box-shadow:none;display:inline-block...
Meteor.subscribe( "songs" ); Template.List.Songs = function() { s = Songs.find({}).fetch(); playing = false; _.each( s, function( ss ){ if( ss.playing && ! playing ) { var a = $("audio#"+ss._id)[0]; if( a ) { con...
window.app.controller ('TestsResultsController', ['$scope', '$rootScope', '$stateParams', '$state', '$filter', '$interval', '$translate', 'notificationsService', 'testsResultsService', function ($scope, $rootScope, $stateParams, $state, $filter, $interval, $translate, notificationsService, testsResultsService) { va...
const express = require("express"); const getJson = require('./getjson.js'); const getStreamers = require('./getstreamers.js'); const bodyParser = require('body-parser'); getJson(); const app = express(); const handlebars = require("express-handlebars").create({ defaultLayout:"main", }); app.engine("handlebars...
(function () { 'use strict'; angular.module('abioka') .service('userService', userService); /* @ngInject */ function userService($cookies) { var user = getDefault(); var rememberMe = false; var service = { getUser: getUser, setUser: setUser, ...
var ServersModel = function () { 'use strict'; var theId, theIp, theHost; this.setId = function (pId) { theId = pId; } this.getId = function () { return theId; } this.setIp = function (pIp) { theIp = pIp; } this.getIp = function () { return theIp...
/** * bd-examples - route.js * Created by mds on 15/6/3. */ 'use strict'; module.exports = function (router, logger) { router.get('/logid', function*(next) { var log = 'app2: ' + this.logid; logger.access(log); this.body = log; yield next; }); };
var i18n = require('../../'); describe('i18n-future', function () { it('exports a function', function () { i18n.should.be.a('function'); }); it('returns a translator instance', function () { i18n().should.be.an.instanceOf(i18n.Translator); }); });
export default { EMAIL_PATTERN: /^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/, ZIP_PATTERN: /^[0-9]{5}(-[0-9]{4})?$/, NUMERIC_PATTERN: /^\d+(,\d{3})*(\.\d*)?$/, PHONE_PATTERN1: /^\([0-9]{3}\)\s[0-9]{3}\s[0...
var fs = require('fs') var path = require('path') var cheerio = require('cheerio') var request = require('request') var MultiPro = require('multi-progress') var Q = require('q') var argv = require('yargs') .alias('h', 'help') .help('help') .usage('Usage: $0 -u <URLs>') .showHelpOnFail(false, 'Specify --help for...
module.exports={A:{A:{"2":"L H G E A B jB"},B:{"1":"8 C D e K I N J"},C:{"1":"0 1 2 3 9 f g h i j k l m n o M q r s t u v w x y z JB IB CB DB EB O GB HB","2":"4 5 7 gB BB F L H G E A B C D e K I N J P Q R S T U V W X Y Z a b c d aB ZB"},D:{"1":"0 1 2 3 8 9 h i j k l m n o M q r s t u v w x y z JB IB CB DB EB O GB HB TB...
var path = require('path'); var webpack = require('webpack'); var ExtractTextPlugin = require('extract-text-webpack-plugin'); var __base = global.__base || __dirname; var process = require('process'); console.log(process.env.NODE_ENV) module.exports = { // or devtool: 'eval' to debug issues with compiled output: d...
'use strict'; angular.module('myApp.view1', ['ngRoute']) .config(['$routeProvider', function($routeProvider) { $routeProvider.when('/view1', { templateUrl: 'view1/view1.html', controller: 'View1Ctrl' }); }]) .controller('View1Ctrl', ['DataManagerService', '$scope', '$rootScope', function(DataManagerServi...
/*global module,require*/ module.exports = function(grunt) { 'use strict'; grunt.registerMultiTask('renderPages', 'Render pages with PhantomJS', function(){ var done = this.async() ,exec = require('child_process').exec ,fs = require('fs') ,mkdirp = require('mkdirp') // ,data = this.data ,sInject = ...
var util = require("util"); var choreography = require("temboo/core/choreography"); /* AllCategories Retrieves all the badge categories in Khan Academy. */ var AllCategories = function(session) { /* Create a new instance of the AllCategories Choreo. A TembooSession object, containing a valid ...
(function() { var HTML_TAGS = [ 'a', 'abbr', 'acronym', 'address', 'applet', 'area', 'article', 'aside', 'audio', 'b', 'base', 'basefont', 'bdi', 'bdo', 'bgsound', 'big', 'blink', 'blockquote', 'body', 'br', 'button', 'canvas', 'caption', 'center', 'cite', 'code', 'col', 'colgroup', 'command', 'data', 'dat...
/* eslint-disable no-useless-escape */ /* eslint-disable no-undef */ /* eslint-disable no-unused-vars */ const sum = (array) => { if (array.length === 0) { return 0; } // eslint-disable-next-line no-confusing-arrow return array.reduce((acum, val) => (!isNaN(val) ? acum + val : 0), 0); }; const ...
var team = team || {}; team.service = { _getUsersByName: function (data, callback) { $.ajax({ url: '/users/getUsersByName', data : data, type: 'GET', dataType: "JSON", success: function(response){ callback && callback.success(respo...