code
stringlengths
2
1.05M
repo_name
stringlengths
5
114
path
stringlengths
4
991
language
stringclasses
1 value
license
stringclasses
15 values
size
int32
2
1.05M
var isArray = Array.isArray; var isPathValue = require("./is-path-value"); var isJsonGraphEnvelope = require("./is-json-graph-envelope"); var isJsonEnvelope = require("./is-json-envelope"); var pathSyntax = require("falcor-path-syntax"); /** * * @param {Object} allowedInput - allowedInput is a map of input styles *...
michaelbpaulson/falcor-1
lib/support/validate-input.js
JavaScript
apache-2.0
1,615
export type from 'test';
wcjohnson/babylon-lightscript
test/fixtures/experimental/export-extensions/default-type-without-flow/actual.js
JavaScript
mit
25
/** * Secure Hash Algorithm with a 1024-bit block size implementation. * * This includes: SHA-512, SHA-384, SHA-512/224, and SHA-512/256. For * SHA-256 (block size 512 bits), see sha256.js. * * See FIPS 180-4 for details. * * @author Dave Longley * * Copyright (c) 2014-2015 Digital Bazaar, Inc. */ (function(...
unki/thallium
public/resources/forge/js/sha512.js
JavaScript
agpl-3.0
18,329
// // iWeb - navbar.js // Copyright (c) 2007-2008 Apple Inc. All rights reserved. // var NavBar=Class.create(Widget,{widgetIdentifier:"com-apple-iweb-widget-NavBar",initialize:function($super,instanceID,widgetPath,sharedPath,sitePath,preferences,runningInApp) {if(instanceID) {$super(instanceID,widgetPath,sharedPath,...
vrdmr/vrdmr.github.io
www/Scripts/Widgets/Navbar/navbar.js
JavaScript
mit
5,986
app.controller('LayersOverlaysMarkersNestedController', ['$scope', 'leafletData','$timeout', function ($scope, leafletData, $timeout) { var _map; leafletData.getMap().then(function(map){ _map = map; }); angular.extend($scope, { ...
ronnpang1/otocopy
www/lib/angular-leaflet-directive-master/examples/js/controllers/LayersOverlaysMarkersNestedController.js
JavaScript
mit
6,000
'use strict'; // TODO(matsko): use caching here to speed things up for detection // TODO(matsko): add documentation // by the time... var $$AnimateJsProvider = ['$animateProvider', /** @this */ function($animateProvider) { this.$get = ['$injector', '$$AnimateRunner', '$$jqLite', function($injector, $$Anim...
Aremyst/angular.js
src/ngAnimate/animateJs.js
JavaScript
mit
8,632
module.exports = { prefix: 'fas', iconName: 'align-justify', icon: [448, 512, [], "f039", "M0 84V44c0-8.837 7.163-16 16-16h416c8.837 0 16 7.163 16 16v40c0 8.837-7.163 16-16 16H16c-8.837 0-16-7.163-16-16zm16 144h416c8.837 0 16-7.163 16-16v-40c0-8.837-7.163-16-16-16H16c-8.837 0-16 7.163-16 16v40c0 8.837 7.163 16 16 16zm0...
evepraisal/go-evepraisal
web/resources/static/thirdparty/fontawesome-free-5.0.8/advanced-options/use-with-node-js/fontawesome-free-solid/faAlignJustify.js
JavaScript
mit
551
module.exports = { prefix: 'fab', iconName: 'tumblr-square', icon: [448, 512, [], "f174", "M400 32H48C21.5 32 0 53.5 0 80v352c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V80c0-26.5-21.5-48-48-48zm-82.3 364.2c-8.5 9.1-31.2 19.8-60.9 19.8-75.5 0-91.9-55.5-91.9-87.9v-90h-29.7c-3.4 0-6.2-2.8-6.2-6.2v-42.5c0-4.5 2.8-8.5 7....
evepraisal/go-evepraisal
web/resources/static/thirdparty/fontawesome-free-5.0.8/advanced-options/use-with-node-js/fontawesome-free-brands/faTumblrSquare.js
JavaScript
mit
573
'use strict'; module.exports.definition = { set: function (v) { this._setProperty('-webkit-border-fit', v); }, get: function () { return this.getPropertyValue('-webkit-border-fit'); }, enumerable: true, configurable: true };
ElvisLouis/code
work/js/node_modules/jsdom/node_modules/cssstyle/lib/properties/webkitBorderFit.js
JavaScript
gpl-2.0
266
// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. /** * @fileoverview A command is an abstraction of an action a user can do in the * UI. * * When the focus changes in the document for each comman...
Chilledheart/chromium
ui/webui/resources/js/cr/ui/command.js
JavaScript
bsd-3-clause
9,731
L.Icon.Canvas=L.Icon.extend({options:{iconSize:new L.Point(20,20),className:"leaflet-canvas-icon"},createIcon:function(){var e=document.createElement("canvas");this._setIconStyles(e,"icon");var s=this.options.iconSize;return e.width=s.x,e.height=s.y,this.draw(e.getContext("2d"),s.x,s.y),e},createShadow:function(){retur...
kiwi89/cdnjs
ajax/libs/leaflet-plugins/1.4.2/layer/Icon.Canvas.min.js
JavaScript
mit
367
'use strict'; /** * Copyright (c) 2014-present, Facebook, Inc. All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of pate...
akhilapnair/exercism-ecmascript
sum-of-multiples/node_modules/jest/node_modules/jest-cli/build/lib/colorize.js
JavaScript
mit
607
var Shader = require('./Shader'); /** * @class * @memberof PIXI * @extends PIXI.Shader * @param shaderManager {ShaderManager} The webgl shader manager this shader works for. * @param [vertexSrc] {string} The source of the vertex shader. * @param [fragmentSrc] {string} The source of the fragment shader. * @param...
nabettu/pixi.js
src/core/renderers/webgl/shaders/TextureShader.js
JavaScript
mit
2,615
(function() { var BINARY_EXTENSIONS, COMPRESSED_EXTENSIONS, IMAGE_EXTENSIONS, MARKDOWN_EXTENSIONS, Module, async, fs, fsPlus, isMoveTargetValid, isMoveTargetValidSync, isPathValid, lstatSyncNoException, mkdirp, path, rimraf, statSyncNoException, _, __slice = [].slice; fs = require('fs'); Module = require('m...
nlhuykhang/atom-config
packages/minimap/node_modules/fs-plus/lib/fs-plus.js
JavaScript
mit
20,254
//// [moduleElementsInWrongContext2.ts] function blah () { module M { } export namespace N { export interface I { } } namespace Q.K { } declare module "ambient" { } export = M; var v; function foo() { } export * from "ambient"; export { foo }; export { baz a...
progre/TypeScript
tests/baselines/reference/moduleElementsInWrongContext2.js
JavaScript
apache-2.0
938
(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);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.ex...
wil93/cdnjs
ajax/libs/forerunnerdb/1.3.477/fdb-all.js
JavaScript
mit
1,042,405
/* XLogin over portal body */ $PBJQ(document).ready(function(){ if( $PBJQ('#loginLink2').length == 1 ){ $PBJQ('#loginLink2').click( function( e ){ $PBJQ('body').append('<div id="Mrphs-xlogin-container" />'); $PBJQ('#Mrphs-xlogin-container').load('/portal/xlogin #Mrphs-xlogin',function(){ $...
ouit0408/sakai
reference/library/src/morpheus-master/js/src/sakai.morpheus.xlogin.js
JavaScript
apache-2.0
898
'use strict' module.exports = Math.PI.toString().slice(0, 6)
wooorm/mdast-usage
test/fixtures/require-last/index.js
JavaScript
mit
62
/*! UIkit 2.24.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */ (function(addon) { var component; if (window.UIkit) { component = addon(UIkit); } if (typeof define == "function" && define.amd) { define("uikit-sticky", ["uikit"], function(){ return component...
dumengnanbuaa/awesome-python-webapp
www/static/js/components/sticky.js
JavaScript
gpl-2.0
12,883
YUI.add('moodle-core-blocks', function (Y, NAME) { /** * Provides drag and drop functionality for blocks. * * @module moodle-core-blockdraganddrop */ var AJAXURL = '/lib/ajax/blocks.php', CSS = { BLOCK : 'block', BLOCKREGION : 'block-region', BLOCKADMINBLOCK : 'block_adminblock', EDITINGMOVE : 'ed...
sameertechworks/wpmoodle
moodle/lib/yui/build/moodle-core-blocks/moodle-core-blocks.js
JavaScript
gpl-2.0
33,181
/* =========================================================== * by.js * Belarusian translation for Trumbowyg * http://alex-d.github.com/Trumbowyg * =========================================================== * Author : Yury Karalkou */ jQuery.trumbowyg.langs.by = { viewHTML: 'Паглядзець HTML', undo: 'С...
sandino/django-trumbowyg
trumbowyg/static/trumbowyg/langs/by.js
JavaScript
mit
1,762
var booleanCondition = require('esmangle-evaluator').booleanCondition; var recast = require('recast'); var types = recast.types; var b = types.builders; var VISITOR_METHODS = { visitLogicalExpression: visitLogicalExp, visitIfStatement: visitCondition, visitConditionalExpression: visitCondition }; module.export...
Phalanstere/WritersStudio
writers_studio-win32-ia32/resources/app/node_modules/unreachable-branch-transform/unreachableBranchTransformer.js
JavaScript
mit
1,993
/** * Module dependencies. */ var fs = require('fs'); var path = require('path'); var assert = require('assert'); var degenerator = require('../'); describe('degenerator()', function () { describe('"expected" fixture tests', function () { fs.readdirSync(__dirname).forEach(function (n) { if ('test.js'...
jphacks/TK_23
web/node_modules/degenerator/test/test.js
JavaScript
mit
1,288
/* MIT License (c) copyright B Cavalier & J Hann */ var p=!0,t=!1; (function(g){function l(){}function s(a,b){return 0==P.call(a).indexOf("[object "+b)}function k(a){return a&&"/"==a.charAt(a.length-1)?a.substr(0,a.length-1):a}function A(a,b){var c,f,d;f=1;a=a.replace(Q,function(a,b,c){c&&f++;d=p;return""});return d?(...
BenjaminVanRyseghem/cdnjs
ajax/libs/curl/0.6.2a/curl-for-dojo1.6/curl.js
JavaScript
mit
7,678
export class DOMSerializer { elementSelector(element) { // iterate up the dom var selectors = []; while (element.tagName !== 'HTML') { var selector = element.tagName.toLowerCase(); var id = element.getAttribute('id'); if (id) { selector += "#" + id; } var className...
IsaacMiguel/aidaScan-App
www/lib/ionic-platform-web-client/src/analytics/serializers.js
JavaScript
mit
1,227
'use strict'; Object.defineProperty(exports, '__esModule', { value: true }); var important = function important(node) { return node.important; }; var unimportant = function unimportant(node) { return !node.important; }; var hasInherit = function hasInherit(node) { return ~node.value.indexOf('inherit');...
puyanLiu/LPYFramework
前端练习/autoFramework/webpack-demo3/node_modules/postcss-merge-longhand/dist/lib/canMerge.js
JavaScript
apache-2.0
780
var assert = require('assert'); var cp = require('child_process'); var fs = require('fs'); var fs_extra = require('fs-extra'); var curDir = fs.realpathSync('.'); var exec_path = process.execPath; var app_path = path.join(curDir, 'internal'); describe('chromium-args', function() { describe('--disable-javascript',...
280455936/nw.js
tests/automation/chromium-args/mocha_test.js
JavaScript
mit
2,565
!function(t){t.datepick.regional.hy={clearText:"Մաքրել",clearStatus:"",closeText:"Փակել",closeStatus:"",prevText:"&#x3c;Նախ.",prevStatus:"",prevBigText:"&#x3c;&#x3c;",prevBigStatus:"",nextText:"Հաջ.&#x3e;",nextStatus:"",nextBigText:"&#x3e;&#x3e;",nextBigStatus:"",currentText:"Այսօր",currentStatus:"",monthNames:["Հունվա...
kiwi89/cdnjs
ajax/libs/datepick/3.7.5/js/jquery.datepick-hy.min.js
JavaScript
mit
1,280
/** * jQRangeSlider * A javascript slider selector that supports dates * * Copyright (C) Guillaume Gautreau 2012 * Dual licensed under the MIT or GPL Version 2 licenses. */ (function($, undefined){ "use strict"; $.widget("ui.rangeSliderDraggable", $.ui.rangeSliderMouseTouch, { cache: null, options: ...
gaearon/cdnjs
ajax/libs/jQRangeSlider/4.2.4/jQRangeSliderDraggable.js
JavaScript
mit
3,375
module.exports={title:"TensorFlow",slug:"tensorflow",svg:'<svg role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><title>TensorFlow icon</title><path d="M19.6 12l.1 4.7-3.1-1.8v6.7L12.5 24V0l10.2 5.9v5.3l-6.1-3.6v2.7zM1.3 5.9L11.5 0v24l-4.1-2.4v-14l-6.1 3.6z"/></svg>',get path(){return this.svg.match(/<p...
cdnjs/cdnjs
ajax/libs/simple-icons/4.4.0/tensorflow.min.js
JavaScript
mit
432
/*! * Backbone.Notifier 3D Module v0.0.3 * Copyright 2012, Eyal Weiss * Backbone.Notifier 3D Module be freely distributed under the MIT license. */ (function (Notifier, $) { Notifier.regModule({ name: '3d', enabled: false, extend: { defaults: { '3d': true ...
gregorypratt/jsdelivr
files/backbone.notifier/0.2.5/js/modules/3d.js
JavaScript
mit
2,876
// Copyright 2013 the V8 project authors. All rights reserved. // Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions o...
zero-ui/miniblink49
v8_7_5/test/webkit/sort-randomly.js
JavaScript
gpl-3.0
2,084
keyboard:function(){var f=this;d(a).keydown(function(h){if(typeof f.options.callforwardFunction==="function"){f.animationCallForward(true)}var g=h.keyCode||h.which;if(h.target.type!=="textarea"&&h.target.type!=="textbox"){if(g===f.options.leftKey){f.setCurrent("right");f.clickable=false}if(g===f.options.rightKey){f.set...
wynandkok/andanonymous
workspace/modules/liquid-slider-keyboard.js
JavaScript
mit
573
'use strict'; !function($) { /** * DropdownMenu module. * @module foundation.dropdown-menu * @requires foundation.util.keyboard * @requires foundation.util.box * @requires foundation.util.nest */ class DropdownMenu { /** * Creates a new instance of DropdownMenu. * @class * @fires DropdownMenu#init ...
mj-wilson/Rachel-Marc-Wedding
wp-content/themes/RachelMarcWedding/assets/components/foundation-sites/js/foundation.dropdownMenu.js
JavaScript
gpl-2.0
12,679
/* YUI 3.16.0 (build 76f0e08) Copyright 2014 Yahoo! Inc. All rights reserved. Licensed under the BSD License. http://yuilibrary.com/license/ */ YUI.add('event-touch', function (Y, NAME) { /** Adds touch event facade normalization properties (touches, changedTouches, targetTouches etc.) to the DOM event facade. Adds t...
dandv/jsdelivr
files/yui/3.16.0/event-touch/event-touch.js
JavaScript
mit
5,190
/* * DOM event listener abstraction layer * @module event * @submodule event-base */ (function() { // Unlike most of the library, this code has to be executed as soon as it is // introduced into the page -- and it should only be executed one time // regardless of the number of instances that use it. var stateCha...
pcarrier/cdnjs
ajax/libs/yui/3.1.0pr2/event/event-debug.js
JavaScript
mit
64,193
IntlMessageFormat.__addLocaleData({"locale":"gv","pluralRuleFunction":function (n,ord){var s=String(n).split("."),i=s[0],v0=!s[1],i10=i.slice(-1),i100=i.slice(-2);if(ord)return"other";return v0&&i10==1?"one":v0&&i10==2?"two":v0&&(i100==0||i100==20||i100==40||i100==60||i100==80)?"few":!v0?"many":"other"}});
Jorginho211/TFG
web/node_modules/intl-messageformat/dist/locale-data/gv.js
JavaScript
gpl-3.0
308
/* backgrid http://github.com/wyuenho/backgrid Copyright (c) 2013 Jimmy Yuen Ho Wong Licensed under the MIT @license. */ (function (root, $, _, Backbone) { "use strict"; /* backgrid http://github.com/wyuenho/backgrid Copyright (c) 2013 Jimmy Yuen Ho Wong Licensed under the MIT @license. */ var wi...
BobbieBel/cdnjs
ajax/libs/backgrid.js/0.1.3/backgrid.js
JavaScript
mit
62,121
(function webpackUniversalModuleDefinition(root, factory) { if(typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("react")); else if(typeof define === 'function' && define.amd) define(["react"], factory); else if(typeof exports === 'object') exports["Slider"] = factory(...
maruilian11/cdnjs
ajax/libs/react-slick/0.6.0/react-slick.js
JavaScript
mit
61,015
/*! * Bootstrap-select v1.6.3 (http://silviomoreto.github.io/bootstrap-select) * * Copyright 2013-2015 bootstrap-select * Licensed under MIT (https://github.com/silviomoreto/bootstrap-select/blob/master/LICENSE) */ (function ($) { $.fn.selectpicker.defaults = { noneSelectedText: 'Niets geselecteerd', non...
jhonrsalcedo/sitio
wp-content/themes/viviendas/assets/libraries/bootstrap-select/dist/js/i18n/defaults-nl_NL.js
JavaScript
gpl-2.0
582
import {has, isArray} from "./util" import {SourceLocation} from "./locutil" // A second optional argument can be given to further configure // the parser process. These options are recognized: export const defaultOptions = { // `ecmaVersion` indicates the ECMAScript version to parse. Must // be either 3, or 5, o...
hellokidder/js-studying
微信小程序/wxtest/node_modules/acorn-jsx/node_modules/acorn/src/options.js
JavaScript
mit
5,026
function thisIsAFunctionWithAVeryLongNameAndWayTooManyParameters(thisIsTheFirstParameter, andThisOneIsRelatedToIt, butNotThisOne, andNeitherThis, inFactThereArentThatManyParameters) { throw null; }
lokiiart/upali-mobile
www/frontend/node_modules/babel-plugin-syntax-trailing-function-commas/test/fixtures/trailing-function-commas/declaration/expected.js
JavaScript
gpl-3.0
200
/** * Copyright 2013-2015, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * * @typechecks * @...
emineKoc/WiseWit
wisewit_front_end/node_modules/react/lib/ReactCSSTransitionGroupChild.js
JavaScript
gpl-3.0
4,805
var _ = require('lodash'); /** * formats variables for handlebars in multi-post contexts. * If extraValues are available, they are merged in the final value * @return {Object} containing page variables */ function formatPageResponse(result) { var response = { posts: result.posts, pagination: ...
norsasono/openshift-ghost-starter
node_modules/ghost/core/server/controllers/frontend/format-response.js
JavaScript
mit
1,048
'use strict'; var times = require('../times'); var moment = require('moment'); function init (ctx) { var translate = ctx.language.translate; var basal = { name: 'basal' , label: 'Basal Profile' , pluginType: 'pill-minor' }; basal.setProperties = function setProperties (sbx) { if (hasRequired...
GarthDB/cgm-remote-monitor
lib/plugins/basalprofile.js
JavaScript
agpl-3.0
5,961
var baseIndexOf = require('./_baseIndexOf'), toInteger = require('./toInteger'); /* Built-in method references for those with the same name as other `lodash` methods. */ var nativeMax = Math.max; /** * Gets the index at which the first occurrence of `value` is found in `array` * using [`SameValueZero`](http://e...
ElvisLouis/code
work/project/Edison/elvis/work/js/node_modules/async/node_modules/lodash/indexOf.js
JavaScript
gpl-2.0
1,232
(function(){ if ( (typeof self === 'undefined' || !self.Prism) && (typeof global === 'undefined' || !global.Prism) ) { return; } var options = { classMap: {} }; Prism.plugins.customClass = { map: function map(cm) { options.classMap = cm; }, prefix: function prefix(string) { options.prefixString = string; ...
ihmcrobotics/ihmc-realtime
websitedocs/website/node_modules/prismjs/plugins/custom-class/prism-custom-class.js
JavaScript
apache-2.0
559
/* YUI 3.17.1 (build 0eb5a52) Copyright 2014 Yahoo! Inc. All rights reserved. Licensed under the BSD License. http://yuilibrary.com/license/ */ YUI.add('event-custom-base', function (Y, NAME) { /** * Custom event engine, DOM event listener abstraction layer, synthetic DOM * events. * @module event-custom */ Y.En...
extend1994/cdnjs
ajax/libs/yui/3.17.1/event-custom-base/event-custom-base-debug.js
JavaScript
mit
75,885
/** * Copyright 2011 Rackspace * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agree...
zendey/Zendey
zendey/platforms/android/cordova/node_modules/elementtree/lib/elementpath.js
JavaScript
gpl-3.0
6,742
var now = require('../time/now') var timeout = require('./timeout') var append = require('../array/append') // ensure a minimum delay for callbacks function awaitDelay (fn, delay) { var baseTime = now() + delay return function () { // ensure all browsers will execute it asynchronously (avoid hard // to ca...
akileez/toolz
src/function/awaitDelay.js
JavaScript
isc
694
import chai from 'chai'; import cas from 'chai-as-promised'; chai.use(cas); export default { expect: chai.expect };
romeovs/all
test/instrument.js
JavaScript
isc
121
'use strict'; var test = require('tap').test, _ = require('lodash'), parse = require('../../../lib/parsers/javascript'), inferMembership = require('../../../lib/infer/membership')(); function toComment(fn, file) { return parse({ file: file, source: fn instanceof Function ? '(' + fn.toString() + ')' : ...
researchgate/documentation
test/lib/infer/membership.js
JavaScript
isc
7,692
'use strict' const t = require('tap') const Parse = require('../lib/parse.js') const makeTar = require('./make-tar.js') const fs = require('fs') const path = require('path') const tardir = path.resolve(__dirname, 'fixtures/tars') const zlib = require('zlib') const MiniPass = require('minipass') const Header = require(...
npm/node-tar
test/parse.js
JavaScript
isc
15,911
// This takes in a set of pairs and writes them to the database. /*jshint node: true */ "use strict"; var csv = require('fast-csv'); var database = require('./database'); var data = csv.fromPath('team.csv', {headers : true}). on("data", function(datum) { database.writeUser({name: datum.User, location: datum.Locat...
tahoemph/random_pairs
import_users.js
JavaScript
isc
345
import capitalize from './util/capitalize'; const unitNames = { npc_dota_roshan_spawner: 'Roshan', dota_item_rune_spawner_powerup: 'Rune', dota_item_rune_spawner_bounty: 'Bounty Rune', ent_dota_tree: 'Tree', npc_dota_healer: 'Shrine', ent_dota_fountain: 'Fountain', npc_dota_fort: 'Ancient',...
devilesk/dota-interactive-map
src/js/getPopupContent.js
JavaScript
isc
2,819
/** Markup under cursor and editing */ var Reflux=require("reflux"); var docfilestore=require("./docfile"); var markupNav=require("../markup/nav"); var markupStore=Reflux.createStore({ listenables:[require("../actions/markup")] ,markupsUnderCursor:[] ,ctrl_m_handler:null ,editing:null ,hovering:null ,onMarkup...
ksanaforge/pannaloka
src/stores/markup.js
JavaScript
isc
2,579
/*jslint node: true*/ "use strict"; var fs = require('fs'), path = require('path'), util = require('util'), protocolHandler = {}, moment = require('moment'); protocolHandler.http = require('http'); protocolHandler.https = require('https'); function asArray(a) { if (Array.isArray(a)) { re...
westtoer/node-winapi
lib/winapi.js
JavaScript
isc
20,578
var sendError = require('../../util/send-error'); // Create a new todo module.exports = function (options) { // Shorter reference to data store var store = options.store; return function (req, res) { var todo = store.todos.filter(function (t) { return t.id === req.params.id; })[0]; // No todo with that i...
wesleytodd/express-todo-api
handlers/todos/assign.js
JavaScript
isc
784
var pi = require('./src/pi'); function run() { pi.send(parseInt(process.argv[2], 10)); setTimeout(run(), 2000); } run();
LucioFranco/bota2015
single.js
JavaScript
isc
128
'use strict' const net = require('net') const assert = require('assert') const eventList = require('../src/event-list') const tcpEmitterServer = require('../src/index') const { net: netUtils, payload: payloadUtils } = require('./utils') describe('TCP Emitter Server Tests:', function () { describe('Scenario: Creatin...
tcp-emitter/server
test/tcp-emitter-server-test.js
JavaScript
isc
29,571
export default { isMobile(window) { return window.innerWidth <= 420 }, generateTranslation(current, columnCount, elWidth, increment) { var position = current.position var value = current.value if (increment) { if (position < columnCount-1) { position = position + 1 } } el...
sprintly/sprintly-kanban
app/views/pages/helpers.js
JavaScript
isc
987
import React from 'react'; import { render } from 'react-dom'; import $ from 'jquery'; import IconAuthorAttrib from './subComponents/iconAuthorAttrib' import site_footer_switch from './helpers/site_footer_switch' export default class Foot extends React.Component { render(){ // console.log(this.props, 'was ...
MelanistOnca/Pers
public/js/foot.js
JavaScript
isc
1,660
import React, { Component } from "react"; import { autobind } from "core-decorators"; import { DiscoverAddressesFormHeader as DiscoverAddressesHeader, DiscoverAddressesFormBody } from "./Form"; @autobind class DiscoverAddressesBody extends Component { constructor(props) { super(props); this.state = this...
oktapodia/decrediton-appveyor-test
app/components/views/GetStartedPage/DiscoverAddresses/index.js
JavaScript
isc
1,439
'use strict'; module.exports = function(err, req, res, next) { let statusCode = err.statusCode || 500; let message = err.message || 'doh!'; let stack = err.stack || ''; res.status(statusCode).json({ message: message, stack: stack }); }
joerx/proto-ci
app/modules/api/error-handler.js
JavaScript
isc
256
// adopted from: https://github.com/fshost/node-dir // Copyright (c) 2012 Nathan Cartwright <fshost@yahoo.com> (MIT) var fs = require('fs') var path = require('path') var mm = require('../glob/minimatch') /** * merge two objects by extending target object with source object * @param target object to merge * @param...
akileez/toolz
src/stream/read-file-stream.js
JavaScript
isc
4,333
var http = require('http'); var util = require('util'); module.exports.createServer = createServer; module.exports.Server = Server; module.exports.install = install; function createServer(listener) { var server = http.createServer.apply(http, arguments); return install(server); } function Server() { ...
AtsushiSuzuki/http-graceful-close
index.js
JavaScript
isc
2,024
const {createServer} = require('http') const {readFileSync} = require('fs') const template = readFileSync(__dirname + '/index.html') createServer((req, res) => { if (req.url === '/favicon.ico') { res.writeHead(404) res.end() } else if (req.headers.referer && req.url !== '/') { res.writeHead(302, { ...
overra/oblink
index.js
JavaScript
isc
447
'use strict'; const XmlNode = require('./XmlNode'); /** A processing instruction within an XML document. @public */ class XmlProcessingInstruction extends XmlNode { /** @param {string} name @param {string} [content] */ constructor(name, content = '') { super(); /** Name of this processing inst...
rgrove/parse-xml
src/lib/XmlProcessingInstruction.js
JavaScript
isc
841
import auth from './authReducer' export { auth }
nattatorn-dev/expo-with-realworld
modules/Auth/reducers/index.js
JavaScript
mit
50
import { h } from 'omi'; import createSvgIcon from './utils/createSvgIcon'; export default createSvgIcon(h("path", { d: "M2 6.67V22h20V6H8.3l8.26-3.34L15.88 1 2 6.67zM7 20c-1.66 0-3-1.34-3-3s1.34-3 3-3 3 1.34 3 3-1.34 3-3 3zm13-8h-2v-2h-2v2H4V8h16v4z" }), 'RadioSharp');
AlloyTeam/Nuclear
components/icon/esm/radio-sharp.js
JavaScript
mit
272
/** * @author: @NikhilS */ require('ts-node/register'); var helpers = require('./helpers'); exports.config = { baseUrl: 'http://localhost:3000/', // use `npm run e2e` specs: [ helpers.root('src/**/**.e2e.ts'), helpers.root('src/**/*.e2e.ts') ], exclude: [], framework: 'jasmine2', allScripts...
nikhilsarvaiye/PeopleManager
config/protractor.conf.js
JavaScript
mit
931
// Include assertion library "Should" var should = require('should'); // jshint ignore:line var PowerupElection = require('polyball/shared/powerups/PowerupElection.js'); var Vote = require('polyball/shared/model/Vote.js'); // An example test that runs using Mocha and uses "Should" for assertion testing describe('Power...
polyball/polyball
polyball/tests/shared/model/PowerupElectionTests.js
JavaScript
mit
3,626
version https://git-lfs.github.com/spec/v1 oid sha256:92a4f24d3a4ad4de3bbed1013b330d5ca23f4d0cbeed4a7536dcd6b3cd3e492d size 4461
yogeshsaroya/new-cdnjs
ajax/libs/dojo/1.7.2/nls/nb/colors.js
JavaScript
mit
129
version https://git-lfs.github.com/spec/v1 oid sha256:50ef15b4c4f47fb98410127b48f1db6e32dc7f759cab685bd27afbfcfd7fdd38 size 23119
yogeshsaroya/new-cdnjs
ajax/libs/yui/3.17.1/jsonp/jsonp-coverage.js
JavaScript
mit
130
/* transparency component */ define([ 'dojo/_base/declare', 'dojo/_base/lang', 'dojo/_base/array', 'dojo/query', 'dojo/dom-style', 'dijit/PopupMenuItem', 'dijit/TooltipDialog', 'dijit/form/HorizontalSlider', 'dijit/form/HorizontalRuleLabels' ], function ( declare, lang, a...
pri0ri7y/OpenMap
js/widgets/templates/layercontrol/plugins/Transparency.js
JavaScript
mit
1,864
// DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE // Version 2, December 2004 // // Copyright (C) 2004 Sam Hocevar <sam@hocevar.net> // // Everyone is permitted to copy and distribute verbatim or modified // copies of this license document, and changing it is allowed as long // as the name is...
beeva-hodeilopez/beeva-data-visualization-hackathon
three-js/map3d.js
JavaScript
mit
4,972
'use strict'; angular.module('ucllApp') .controller('LogoutController', function (Auth) { Auth.logout(); });
craftworkz/ucll-workshop-jhipster
jhipster-demo/src/main/webapp/scripts/app/account/logout/logout.controller.js
JavaScript
mit
126
/* * Copyright (C) 2012 David Geary. This code is from the book * Core HTML5 Canvas, published by Prentice-Hall in 2012. * * License: * * Permission is hereby granted, free of charge, to any person * obtaining a copy of this software and associated documentation files * (the "Software"), to deal in the Softwar...
yuesir/HTML5-Canvas
ch03/example-3.9/example.js
JavaScript
mit
4,545
// @flow import React, { type Node } from 'react'; import classnames from 'classnames'; import { Tooltip as ReactAccessibleTooltip } from 'react-accessible-tooltip'; import './tooltip.scss'; function Tooltip({ label, overlay }: { label: Node, overlay: Node }) { return ( <ReactAccessibleTooltip ...
ryami333/react-accessible-tooltip
packages/docs/src/components/Tooltip/Tooltip.js
JavaScript
mit
1,166
var router = new AiRouter(); router.route('/',{ name:'HOME', action:function(params, query) { document.getElementById("switch").innerHTML = "Changed to Home page!"; console.log('Home Page'); }, }); router.route('/projects/:projectId/tests/:testId',{ name:'HOME', action:function(par...
nedyalkovV/AiRouter
demo/demo/demo.js
JavaScript
mit
1,653
User.inject({ statics: { log: function() { var str = Array.create(arguments).join(' '); if (session && session.user) str = '[' + session.user.name + '] ' + str; app.log(str); }, logError: function(title, e) { var shortDesc = (e.fileName ? 'Error in ' + e.fileName + ', Line ' + e.lineNumber ...
lehni/boots
base/helma/User/functions.js
JavaScript
mit
1,599
/** * @since 2019-07-19 14:13 * @author vivaxy * * Call simple function. 7.964s * Call function await promise. 16.687s * Call function with if logic. 9.612s */ let resolved = false; function request() { return new Promise(function(resolve) { setTimeout(function() { resolve(true); }, 1000); });...
vivaxy/course
benchmark/await-resolved-promise/index.js
JavaScript
mit
1,223
'use strict'; FbFriends.StatsView = Backbone.View.extend({ events: { }, initialize: function(options) { _.extend(this, options); this.friends.on('reset', this.render, this); }, render: function(event) { this.showSexRepartition(); // this.showTopVille(); this.showR...
FXHibon/facebook-fun
frontend/app/friends/statistics/StatsView.js
JavaScript
mit
4,807
'use strict'; const Perceptron = require('./perceptron'); const PerceptronTrainer = require('./perceptron.trainer'); const trainer = new PerceptronTrainer(); trainer.setLearningRate(2.0); // and-perceptron: weights: [1,4], bias: -5 const perceptron = new Perceptron(); perceptron.setWeights([-20,-30]); perceptron.se...
pascalvree/example-perceptron-implementation
src/example.js
JavaScript
mit
998
import { getElementIfNotEmpty } from './getElementIfNotEmpty.js'; export function getStackDataIfNotEmpty(viewportIndex) { const element = getElementIfNotEmpty(viewportIndex); if (!element) { return; } const stackToolData = cornerstoneTools.getToolState(element, 'stack'); if (!stackToolData...
NucleusIo/HealthGenesis
viewerApp/Packages/ohif-viewerbase/client/lib/getStackDataIfNotEmpty.js
JavaScript
mit
518
// Load the test base const reload = require('require-reload')(require); const tests = reload('../base/tests'); module.exports = function promiseTestRunner (qb) { Object.keys(tests).forEach(describeName => { describe(describeName, async () => { let currentSuite = tests[describeName]; Object.keys(currentSuite)...
timw4mail/node-query
test/base/adapterPromiseTestRunner.js
JavaScript
mit
6,181
var Quad = Class.create(Renderable, { initialize: function($super, width, height, position) { this.width = width; this.height = height; $super(); if (position) this.orientation.setPosition(position); }, setWidth: function(width) { this.setSize(width, this.height); }, setHeight: function(heigh...
sinisterchipmunk/rails-webgl
public/javascripts/objects/quad.js
JavaScript
mit
1,039
/* * SpriteContainer * Visit http://createjs.com/ for documentation, updates and examples. * * Copyright (c) 2010 gskinner.com, inc. * * Permission is hereby granted, free of charge, to any person * obtaining a copy of this software and associated documentation * files (the "Software"), to deal in the Software without ...
iwangx/createjs
src/easeljs/display/SpriteContainer.js
JavaScript
mit
7,122
/** * Babel plugin for removing specific properties that match a given regular expression. * */ "use strict"; exports.default = function() { return { visitor: { // ObjectProperty Visitor ObjectProperty: function ObjectProperty(path, state) { /** ...
bdupharm/babel-plugin-remove-object-properties
lib/plugin.js
JavaScript
mit
998
// Simple JavaScript Templating // Heavily based on: John Resig - http://ejohn.org/blog/javascript-micro-templating/ var argName = 'data'; function getFuncBody(str) { return argName+"="+argName+"||{};var p=[];p.push('" + str .replace(/[\r\t\n]/g, " ") .split("<%").join("\t") .replace(/((^|%>)[^\t]*)'...
theakman2/node-modules-mtmpl
lib/index.js
JavaScript
mit
756
'use strict'; var nodeSassImport = require('../'); var test = require('tape'); var sass = require('node-sass'); test('base:function:test', function (t) { t.ok(typeof nodeSassImport === 'function'); t.end(); }); test('base:importer:test', function (t) { sass.render({ file: 'test/fixtures/main.scss', imp...
anarh/node-sass-import
test/index.js
JavaScript
mit
830
"use strict"; const assert = require("assert"); const Message = require("../lib/vehicle-message"); describe("vehicle-message", () => { it("get MQTT packet and return VehicleMessage data model", () => { const msg = Message.from({ topic: "vehicle/foo", payload: new Buffer(JSON.stringify({ time...
esmusssein/SNU-grad-proj
broker/test/vehicle-message.js
JavaScript
mit
1,804
'use strict'; // http://stackoverflow.com/a/365853 Object.defineProperty(exports, "__esModule", { value: true }); exports.toRad = toRad; exports.getShortestDistance = getShortestDistance; exports.getLonguestDistance = getLonguestDistance; exports.getLonguestDistanceFromCoordinates = getLonguestDistanceFromCoordinat...
alexjab/node-simple-eta
lib/distances.js
JavaScript
mit
1,850
$(function() { var background = chrome.extension.getBackgroundPage(); var defaultOptions = background.defaultOptions; var options = {}; function createFrames() { var frames = options.frames.split('\n'); $('.js-frame').remove(); for (var i = 0; i < frames.length; i++) { var src = frames[i]; ...
laurentguilbert/overseer
js/frames.js
JavaScript
mit
1,827
module.exports = { presets: [ [ '@babel/preset-env', { targets: { node: '12', }, }, ], '@babel/preset-react', ], };
dannegm/danielgarcia
.babelrc.js
JavaScript
mit
236
/* * Module dependencies */ var conf = module.exports = require('nconf'); /* Last fallback : environment variables */ conf.env().argv(); /* Dev fallback : config.json */ conf.file(__dirname + '/../config.json'); /* Default values */ conf.defaults({ title: 'Meishengo', debug: false, port: 8000, host: '...
dawicorti/meishengo
lib/conf.js
JavaScript
mit
372
module.exports = { mixins: [__dirname], fragmentsFile: '<rootDir>/fragmentTypes.json', graphqlMockServerPath: '/graphql', configSchema: { fragmentsFile: { type: 'string', absolutePath: true, }, graphqlSchemaFile: { type: 'string', absolutePath: true, }, graphqlMockSch...
xing/hops
packages/apollo-mock-server/preset.js
JavaScript
mit
493
import { CHOOSE_MEMORY, LOAD_PHOTO_ERROR, LOAD_PHOTO_SUCCESS, } from './constants'; export function chooseMemory({ id, index }) { return { type: CHOOSE_MEMORY, id, index, }; } export function photoLoadSuccess({ host, gallery, setCurrentMemory, album, id, photoLink, }) { return { ...
danactive/history
ui/app/containers/App/actions.js
JavaScript
mit
556
function saveUser({state, input}) { state.set(['user', 'user'], input.user); state.set(['session', 'jwt'], input.jwt); } export default saveUser;
testpackbin/testpackbin
app/modules/home/actions/saveUser.js
JavaScript
mit
151
import React from 'react'; import createSvgIcon from './utils/createSvgIcon'; export default createSvgIcon( <React.Fragment><path d="M20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69L23.31 12 20 8.69zm-2 5.79V18h-3.52L12 20.48 9.52 18H6v-3.52L3.52 12 6 9.52V6h3.52L12 3.52 14.48 ...
kybarg/material-ui
packages/material-ui-icons/src/Brightness7Outlined.js
JavaScript
mit
593