commit stringlengths 40 40 | subject stringlengths 1 3.25k | old_file stringlengths 4 311 | new_file stringlengths 4 311 | old_contents stringlengths 0 26.3k | lang stringclasses 3
values | proba float64 0 1 | diff stringlengths 0 7.82k |
|---|---|---|---|---|---|---|---|
53913a9a2b1254aa0f0d9023a5d3d47ba84cb303 | add tests | test/test.js | test/test.js | JavaScript | 0 | @@ -0,0 +1,830 @@
+/* global describe, it */%0Avar assert = require('assert');%0Avar Fiunis = require('../');%0A%0Adescribe(%22Fidonet Unicode strings' decoder%22, function()%7B%0A it('leaves some simple text untouched', function()%7B%0A var lorem = %5B%0A 'Lorem ipsum dolor sit amet, consectetur adipisi... | |
05d59a741201f394c56dcf21b5dbed039c69ae4d | fix exports options | lib/sdk/option.js | lib/sdk/option.js | var path = require('path');
var _ = require('underscore');
var defaultValues = {
cachedir: '.cache',
// nico should rebuild the cache or not
cachetag: '0.1.0',
sourcedir: 'content',
outputdir: '_site',
encoding: 'utf8',
tocLevel: 3,
engine: 'swig',
reader: null,
ignorecvs: true
};
var defaultMap... | JavaScript | 0.000006 | @@ -1155,114 +1155,8 @@
%7D;%0A%0A
-try %7B%0A // share single instance%0A exports = module.exports = require('nico').sdk.option;%0A%7D catch (e) %7B%0A
expo
@@ -1192,17 +1192,16 @@
tion();%0A
-%7D
%0Aexports
|
9cbc6e2317d3908802d26a818c5e347eb9d6e47f | add minified | parse-form-min.js | parse-form-min.js | JavaScript | 0 | @@ -0,0 +1,426 @@
+// Parse Form - https://github.com/AdamBrodzinski/parse-form%0AParseForm=function(a)%7Bvar b=this;return a?(this.$el=$(a),this.el=this.$el%5B0%5D,this.inputs=this.$el.serializeArray(),$.each(this.inputs,function(a)%7Bvar d=b.inputs%5Ba%5D.name;b%5Bd%5D=b.inputs%5Ba%5D.value,b%5B%22$%22+d%5D=b.$el.fin... | |
7c9f4561202f692bd0836665c75e20ceeb7f8169 | ADD a dummy User model in user.js | app/models/user.js | app/models/user.js | JavaScript | 0.000002 | @@ -0,0 +1,184 @@
+var mongoose = require('mongoose');%0A%0Amodule.exports = mongoose.model('User', %7B%0A%09name : %7Btype : String, default: ''%7D,%0A%09crews : %5B%5D,%0A%09dateCreated : %7Btype : Date, default: Date.now()%7D%0A%7D);%0A
| |
47edcfc8fffd33a3930779d370421f9033b805a5 | Add user model | app/models/user.js | app/models/user.js | JavaScript | 0.000001 | @@ -0,0 +1,139 @@
+import DS from 'ember-data';%0A%0Aexport default DS.Model.extend(%7B%0A%09name: DS.attr('string'),%0A%09logins: DS.attr('number', %7BdefaultValue: 0%7D)%0A%7D);%0A
| |
aa84328407275afc7e00dd00c73c348324f3fe87 | add snippet of how to construct html element | jscode.js | jscode.js | JavaScript | 0.000001 | @@ -0,0 +1,1676 @@
+ /* Example of how to construct html elements using jQuery */%0A var dialog = $(%22%3Cdiv/%3E%22, %7B%0A 'class':'control-list-action twitter-bootstrap',%0A 'id':%22control-action%22%0A %7D).append(%0A $(%22%3Cdiv/%3E%22, %7B%0A ... | |
3ebeb7e5f32943f6b1f0b78419f28c0660da693b | model task prompts | model/prompts.js | model/prompts.js | JavaScript | 0.999999 | @@ -0,0 +1,586 @@
+(function IIFE() %7B%0A 'use strict';%0A%0A function makePrompts(defaults) %7B%0A const prompts = Object.freeze(%5B%7B%0A name: 'modelName',%0A message: 'What is the name of your model?',%0A validate: function(input) %7B%0A var done = this.async();%0A%0A if(/%5E(%5BA... | |
b8f4401aa1fe2513427ed4e3311ec45729bb6fb3 | Create the spark only when the `open` event is fired | transformers/faye/server.js | transformers/faye/server.js | 'use strict';
var http = require('http')
, parse = require('url').parse;
/**
* Minimum viable WebSocket server for Node.js that works through the Primus
* interface.
*
* @runat server
* @api private
*/
module.exports = function server() {
var Faye = require('faye-websocket')
, Spark = this.Spark;
//
... | JavaScript | 0.000001 | @@ -344,16 +344,17 @@
requests
+.
%0A //%0A
@@ -519,76 +519,198 @@
ead)
+;%0A
%0A
- , spark = new Spark(%0A req.headers
+//%0A // The WebSocket handshake is complete only when the %60open%60 event is fired.%0A //%0A websocket.on('open', function open() %7B%0A var sp... |
87dce25f3d868cfc11c23f45fa95457d07c4c037 | Use ReactJS production build in Webpack production | webpack.production.config.js | webpack.production.config.js | const webpack = require('webpack');
const path = require('path');
const fs = require('fs');
const ExtractTextPlugin = require("extract-text-webpack-plugin");
const HtmlWebpackPlugin = require('html-webpack-plugin');
const nodeModulesPath = path.resolve(__dirname, 'node_modules');
const buildPath = path.resolve(__dirnam... | JavaScript | 0 | @@ -388,16 +388,265 @@
.js');%0A%0A
+const pathToReact = path.resolve(nodeModulesPath, 'react/dist/react.min.js');%0Aconst pathToReactDom = path.resolve(nodeModulesPath, 'react-dom/dist/react-dom.min.js');%0Aconst pathToReactObj = path.resolve(nodeModulesPath, 'react/lib/Object.assign');%0A%0A
const co
@@ -654,16 +65... |
8e1afd54645731ae67d115506e2a9cff418e2980 | Introduce GridBlock component that doesn't parse markdown | website/core/AltGridBlock.js | website/core/AltGridBlock.js | JavaScript | 0 | @@ -0,0 +1,2583 @@
+/**%0A * Copyright (c) Facebook, Inc. and its affiliates.%0A *%0A * This source code is licensed under the MIT license found in the%0A * LICENSE file in the root directory of this source tree.%0A *%0A * @format%0A */%0A%0A'use strict';%0A%0Aconst React = require('react');%0A%0Aconst classNames = req... | |
89fe2b1a54b35f0a725aef7892f3481532a925af | add e2e test | assets/js/samplefeature/tests/e2e/samplefeature.scenario.js | assets/js/samplefeature/tests/e2e/samplefeature.scenario.js | JavaScript | 0.000049 | @@ -0,0 +1,481 @@
+describe('When accessing the sample features', function() %7B%0A%0A beforeEach(function() %7B%0A browser.get('/');%0A %7D);%0A%0A it('the default url should be set correctly', function() %7B%0A expect(browser.getLocationAbsUrl()).toEqual('/');%0A %7D);%0A%0A it('clicking the next page butt... | |
995430836d4dca552613f7f545df67ea95a10bfe | fix (url sync): do not add empty string valued props to the url search | src/searchParams.js | src/searchParams.js | export function toQuery (params) {
const tokens = []
for (let key in params) {
const value = params[key]
if (value !== undefined) {
tokens.push(`${encodeURIComponent(key)}=${encodeURIComponent(value)}`)
}
}
return tokens.length ? '?' + tokens.join('&') : ''
}
export function toParams (query) ... | JavaScript | 0.000001 | @@ -133,16 +133,32 @@
ndefined
+ && value !== ''
) %7B%0A
|
7d98b7d1d4e439c13176b67768743d1969061d01 | Word-order-insensitive | src/simplesearch.js | src/simplesearch.js | var SimpleSearch = {};
SimpleSearch.isAlphaNumeric = function (str) {
var code, i, len;
// iterating and checking charCode is uglier but faster than regexp
// http://jsperf.com/alphanumeric-charcode-vs-regexp
for (i = 0, len = str.length; i < len; i++) {
code = str.charCodeAt(i);
if (!(code > 47 && co... | JavaScript | 0.999902 | @@ -526,18 +526,26 @@
ch.match
-es
+SingleWord
= funct
@@ -549,20 +549,20 @@
nction (
-item
+word
, search
@@ -575,42 +575,8 @@
var
-_item = item.toLowerCase(),%0A
prev
@@ -1040,21 +1040,20 @@
Index =
-_item
+word
.indexOf
@@ -1230,24 +1230,24 @@
Index;%0A %7D%0A%0A
-
return tru
@@ -1245,32 +1245,... |
3096f1459e19708c8c825324019300cc358fce3c | add esperanto to international.js | international.js | international.js | function hello(language) {
var hellos = {
'Chinese': '你好世界',
'Dutch': 'Hello wereld',
'English': 'Hello world',
'French': 'Bonjour le monde',
'German': 'Hallo Welt',
'Greek': 'γειά σου κόσμος',
'Italian': 'Ciao mondo',
'Japanese': 'こんにちは世界',
'Korean': '안녕하세요 세계',
'Portuguese': ... | JavaScript | 0.999108 | @@ -115,24 +115,58 @@
llo world',%0A
+ 'Esperanto': 'Saluton mondo',%0A
'French'
|
b5c9b1e728e11df7825003339a37cd93d0239639 | Include more data in loader.js report | js-src/loader.js | js-src/loader.js | $(function (){
var loc = location.hash.length < 2 ? "welcome.html" : location.hash.substring(1);
loader(loc);
});
var loader = function (s) {
// load content from server
$.get(s, function (data){
var result = $(data);
$("#content").html(result);
// send event to Google Analytics
ga(... | JavaScript | 0 | @@ -349,17 +349,35 @@
'load',
-s
+location.toString()
);%0A
|
3637584f3c858a5025494d508193302e8a1cd8f8 | Add minimal sanity test for hamjest exports | test/hamjestSpec.js | test/hamjestSpec.js | JavaScript | 0 | @@ -0,0 +1,364 @@
+'use strict';%0A%0Avar _ = require('lodash-node')%0A%09, hamjest = require('../lib/hamjest')%0A%09, assertFalse = require('./asserts').assertFalse%0A%09;%0A%0Adescribe('hamjest', function () %7B%0A%09it('should not export undefined matchers', function () %7B%0A%09%09_.forEach(hamjest, function (value... | |
a38d85b0914b7fbcd3e30d7776390605d6c08d4e | Add fishing and consume example | examples/fisherman.js | examples/fisherman.js | JavaScript | 0 | @@ -0,0 +1,1723 @@
+const mineflayer = require('mineflayer')%0A%0Aif (process.argv.length %3C 4 %7C%7C process.argv.length %3E 6) %7B%0A console.log('Usage : node scoreboard.js %3Chost%3E %3Cport%3E %5B%3Cname%3E%5D %5B%3Cpassword%3E%5D')%0A process.exit(1)%0A%7D%0A%0Aconst bot = mineflayer.createBot(%7B%0A host: pr... | |
a22165d62c9aa06efd4aceb234e07a9a61d4f7b1 | add datbase wrapper | lib/db.js | lib/db.js | JavaScript | 0 | @@ -0,0 +1,660 @@
+'use strict';%0A%0Aconst mongoose = require('mongoose');%0A%0Aif (mongoose.connection._hasOpened) %7B%0A module.exports = mongoose;%0A%7D else %7B%0A let mongoUri = process.env.MONGO_URI;%0A%0A if (typeof mongoUri === 'undefined' %7C%7C !mongoUri) %7B%0A if (!process.env.MONGO_DB) %7B%0A t... | |
be56ae0d1edc769880c3596a32938ee554855c13 | Create logger module | scripts/config/logger.config.js | scripts/config/logger.config.js | JavaScript | 0.000001 | @@ -0,0 +1,1561 @@
+/**%0A * @fileOverview The logging facilities.%0A */%0A%0Avar moment = require('moment/moment');%0A%0A/**%0A * Log decorator for applying timestamp to all log messages.%0A *%0A * @param %7BObject%7D $provide The $provide service.%0A */%0Avar logConfig = module.exports = function ($provide) %7B%0A $... | |
c44c5a7d3217d305b59245921d595b9bd5032133 | Create customdns.js | scripts/pi-hole/js/customdns.js | scripts/pi-hole/js/customdns.js | JavaScript | 0 | @@ -0,0 +1,1855 @@
+var table;%0A%0A$(document).ready(function() %7B%0A%0A $('#btnAdd').on('click', addCustomDNS);%0A%0A table = $(%22#customDNSTable%22).DataTable( %7B%0A %22ajax%22: %22scripts/pi-hole/php/customdns.php?action=get%22,%0A %22columnDefs%22: %5B %7B%0A %22targets%22: 2,%0A ... | |
ad4195ee5f2bd2c7ec276d62b8ae7f2a22545281 | add working async version | MyFirstAsyncIO.js | MyFirstAsyncIO.js | JavaScript | 0 | @@ -0,0 +1,168 @@
+var fs = require('fs');%0A%0Afs.readFile(process.argv%5B2%5D, function callback (err, data) %7B%0A%09var newLines = data.toString().split(%22%5Cn%22);%0A%09console.log(newLines.length-1);%0A%7D);%0A
| |
503d6b27de29a2e516a9426147ae6673f0db9446 | move into separate file | lib/polyfills.js | lib/polyfills.js | JavaScript | 0.000002 | @@ -0,0 +1,908 @@
+// https://gist.github.com/paulirish/1579671%0A(function() %7B%0A var lastTime = 0;%0A var vendors = %5B'webkit', 'moz'%5D;%0A for(var x = 0; x %3C vendors.length && !window.requestAnimationFrame; ++x) %7B%0A window.requestAnimationFrame = window%5Bvendors%5Bx%5D+'RequestAnimationFrame'%5D;%0A ... | |
2b15086d857c9b4997f3d83fe16576bfe84d92b1 | Create pt-PT.js | app/assets/javascripts/tinymce/plugins/uploadimage/langs/pt-PT.js | app/assets/javascripts/tinymce/plugins/uploadimage/langs/pt-PT.js | JavaScript | 0.000001 | @@ -0,0 +1,511 @@
+tinyMCE.addI18n('pt-PT', %7B%0A 'Insert an image from your computer': 'Inserir uma imagem do seu computador',%0A 'Insert image': 'Inserir imagem',%0A 'Choose an image': %22Escolher uma imagem%22,%0A 'You must choose a file': %22%C3%89 necess%C3%A1rio seleccionar um ficheiro%22,%0A 'Got a bad res... | |
af13e80dee501a7820d8e1fe065b6a189e2e41df | Add a CLI test, fixes #26 | packages/node-sass-selector-importer/test/cli.js | packages/node-sass-selector-importer/test/cli.js | JavaScript | 0 | @@ -0,0 +1,652 @@
+/* eslint-env node, mocha */%0Aconst exec = require(%60child_process%60).exec;%0Aconst expect = require(%60chai%60).expect;%0Aconst fs = require(%60fs%60);%0A%0A/** @test %7Bcli%7D **/%0Adescribe(%60cli%60, () =%3E %7B%0A it(%60should convert a SASS file to CSS%60, (done) =%3E %7B%0A // eslint-di... | |
4a1389a2844388d11b595a7fc7cf85213ce2e221 | Create handling of accountKit in client side | public/javascript/accountKitLogin.js | public/javascript/accountKitLogin.js | JavaScript | 0 | @@ -0,0 +1,1471 @@
+// initialize Account Kit with CSRF protection%0A AccountKit_OnInteractive = function () %7B%0A AccountKit.init(%0A %7B%0A appId: '169812573551460',%0A state: 'csrf',%0A version: 'v1.1',%0A fbAppEventsEnabled: true,%0A debug: true%0A %7D%0A )%0A %... | |
194417c40daa20312cc4d67c83eb30c6bc21efbc | add JS file | MeowRTC/browser/demos/demo-4/MeowScript.js | MeowRTC/browser/demos/demo-4/MeowScript.js | JavaScript | 0.000001 | @@ -0,0 +1,592 @@
+window.onload = function() %7B%0A %0A%0A var video = document.getElementById(%22video%22);%0A var canvas = document.getElementById(%22canvas%22);%0A var pictureButton = document.getElementById(%22takePicture%22);%0A var stopButton = document.getElementById(%22stop%22);%0A%0A var webcam = new We... | |
c7eca88c6973f6585077c0832c206bf02e720121 | Create postcss.config.js | postcss.config.js | postcss.config.js | JavaScript | 0.000003 | @@ -0,0 +1,59 @@
+module.exports = %7B%0A plugins: %7B%0A autoprefixer: %7B%7D%0A %7D%0A%7D%0A
| |
49f2e660460a8fe3efb64e8037dd5a943f3a9999 | Add the controller for the type racer game. | public_html/type-racer-controller.js | public_html/type-racer-controller.js | JavaScript | 0 | @@ -0,0 +1,1668 @@
+function TypeRacerCtrl($scope) %7B%0A this.selectedLevelName;%0A this.selectedLevelSpeed;%0A this.playerName;%0A %0A this.$onInit = function() %7B%0A this.levels = %5B%0A %7B%0A levelName: 'Beginner',%0A charsPerSecond: 3%0A %... | |
bb471dc55d06a5851acd35bb4ca79ee3811c6f0a | Add tests to Spinner component | packages/es-components/src/components/base/spinner/Spinner.specs.js | packages/es-components/src/components/base/spinner/Spinner.specs.js | JavaScript | 0 | @@ -0,0 +1,965 @@
+/* eslint-env jest */%0A%0Aimport React from 'react';%0Aimport %7B render, cleanup %7D from 'react-testing-library';%0Aimport Spinner from './Spinner';%0A%0AbeforeEach(cleanup);%0A%0Ait('does not include title when not provided', () =%3E %7B%0A const %7B queryByText %7D = render(%0A %3CSpinner de... | |
1da3e4e3eb8d1603a1f3383bdd78c8ff802f30c8 | Create Trainer.user.js | HentaiVerse/Trainer.user.js | HentaiVerse/Trainer.user.js | JavaScript | 0.000002 | @@ -0,0 +1,2432 @@
+// ==UserScript==%0A// @name Trainer%0A// @namespace https://github.com/dodying/Dodying-UserJs%0A// @include http://hentaiverse.org/*%0A// @version 1%0A// @grant none%0A// @require http://libs.baidu.com/jquery/1.9.1/jquery.min.js%0A// @run-at document-end%0A// ==/User... | |
c3a99e2a9f250e52d97346725a6da1fd180668ed | Create index.js | index.js | index.js | JavaScript | 0.000002 | @@ -0,0 +1 @@
+%0A
| |
89499b6a94976d71df6ab4683ff00ca0b7e446df | Add some route matching | index.js | index.js | JavaScript | 0.000001 | @@ -0,0 +1,1642 @@
+var url = require('url');%0A%0Aconst PATH_NOT_FOUND_ERROR = %7B%0A%09errorCode:404,%0A%09error:'$PATH is not a known route.'%0A%7D%0A%0Aconst ARGUMENT_PATTERN = new RegExp(%22:%5B%5E %5C/%5D*%22);%0A%0Amodule.exports = Timpani%0A%0Afunction Timpani(routes)%7B%0A%09if (routes!=undefined)%7B%0A%09%09t... | |
9a16ad82a99567471bae0301b229cea2c6910192 | add index.js | index.js | index.js | JavaScript | 0.000005 | @@ -0,0 +1,405 @@
+%0A%0A%0A// word1 word2 https://github.com/thibaultfriedrich-backup/test-raven.git%0Afunction toto () %7B%0A%0A%7D%0A%0A// https://github.com/thibaultfriedrich-backup/test-raven.git word3 word4%0Afunction titi () %7B%0A%0A%7D%0A%0A/**%0A * word1 word2%0A * https://github.com/thibaultfriedrich-backup/... | |
210e18fc0cef80442c273d6af63efb6755fcdaad | Create index.js | index.js | index.js | JavaScript | 0.000002 | @@ -0,0 +1,280 @@
+class GameObject %7B%0A constructor(sName,baseCost) %7B%0A this.name = sName;%0A this.amount = 0;%0A this.baseCost = baseCost;%0A %7D%0A%7D%0A%0A%0A// Init:%0AGame = %7B%7D;%0A%0AGame.version = %22v0.0.0ppa%22;%0AGame.Objects = %7B%7D%0A%0AGame.code = 0;%0A// Game.%0AGame.Objects.Keyboard ... | |
e2a2dd32f6af7a62e5dd574fb687d5f2b2990d9f | Create index.js | index.js | index.js | JavaScript | 0.000002 | @@ -0,0 +1,204 @@
+module.exports = %7B%0A%09AND : function(a, b) %7B%0A%09%09return ((a & b));%0A%09%7D,%0A%09OR : function(a, b) %7B%0A%09%09return ((a %7C b));%0A%09%7D,%0A%09Conversion : function(number, toRadix) %7B%0A%09%09return (number %3E%3E%3E 0).toString(toRadix);%0A%09%7D%0A%7D%0A
| |
91f53c1af8af18948ab1df4e8015e515c7ac4644 | Add basic server file | index.js | index.js | JavaScript | 0.000001 | @@ -0,0 +1,1275 @@
+var express = require('express')%0A , env = require('envoodoo')%0A , fs = require('fs')%0A%0Aenv()%0A%0Avar filename = process.env.GAME_FILE_NAME%0A%0Avar app = express()%0A%0Aapp.post('/game', function (req, res) %7B%0A var write = fs.createWriteStream(%5B%0A __dirname,%0A ... | |
8610a05bc207b7506c2d1f3efda13e2d8308595e | Add ember-disable-prototype-extensions to addons by default. | blueprints/addon/index.js | blueprints/addon/index.js | var fs = require('fs');
var path = require('path');
var walkSync = require('walk-sync');
var stringUtil = require('../../lib/utilities/string');
var assign = require('lodash-node/modern/objects/assign');
var uniq = require('lodash-node/underscore/arrays/uniq');
var Blueprint = require(... | JavaScript | 0 | @@ -937,16 +937,17 @@
s %7C%7C %7B%7D%0A
+%0A
// n
@@ -1317,24 +1317,173 @@
n');%0A %7D%0A%0A
+ // add %60ember-disable-prototype-extensions%60 to addons by default%0A contents.devDependencies%5B'ember-disable-prototype-extensions'%5D = '%5E1.0.0';%0A%0A
contents
|
65a23a68a2cdf389d2091f59da333c6933ce49da | Reset reflection id while running tests | test/converter.js | test/converter.js | var TD = require("../bin/typedoc.js");
var FS = require('fs');
var Path = require('path');
var Assert = require("assert");
function compareReflections(fixture, spec, path) {
var key;
path = (path ? path + '/' : '') + spec.name;
for (key in spec) {
if (!spec.hasOwnProperty(key)) continue... | JavaScript | 0 | @@ -2508,24 +2508,64 @@
putFiles();%0A
+ TD.resetReflectionID();%0A
|
eb6590a9b0685b1f36905bacfec1f1a9027f00d4 | Add test script for the Nippon kiosk printer | tools/nipponPrinterTests.js | tools/nipponPrinterTests.js | JavaScript | 0 | @@ -0,0 +1,1511 @@
+const minimist = require('minimist')%0Aconst SerialPort = require('serialport')%0A%0Aconst portOptions = %7B%0A autoOpen: false,%0A baudRate: 115200,%0A parity: 'odd',%0A dataBits: 8,%0A stopBits: 1,%0A rtscts: false,%0A xon: true,%0A xoff: true%0A%7D%0A%0Aconst args = minimist(process.argv.... | |
2d51636e3c1534765d2816ca1ef5067b07a447b4 | Add the spec | test/angular-uploadcare.spec.js | test/angular-uploadcare.spec.js | JavaScript | 0.000026 | @@ -0,0 +1,987 @@
+var uploadcareGlobalSettings = %7B%0A 'UPLOADCARE_PUBLIC_KEY': 'demopublickey',%0A 'UPLOADCARE_LIVE': true%0A%7D%0A%0Adescribe('ng-uploadcare: ', function() %7B%0A var $compile,%0A $rootScope;%0A%0A beforeEach(function(done) %7B%0A var scriptEl = document.createElement('script');%0A%0A f... | |
ad48d386a1495cd0409b83050e71c0a1a6a5b1dd | introduce jquery.scrollspy.js | public/js/jquery.scrollspy.js | public/js/jquery.scrollspy.js | JavaScript | 0.000001 | @@ -0,0 +1,2011 @@
+;(function ($) %7B%0A var defaults = %7B%0A approach: 0,%0A overtravel: 0%0A %7D;%0A%0A /*%0A Trigger appropriate events when the selected element is scrolled in or%0A out of view.%0A%0A An element is considered to be in view if the length of document%0A... | |
efa506fe49b62a4ddf228c6e1be6e5147a323471 | Add test/compound.js | tests/compound.js | tests/compound.js | JavaScript | 0.000002 | @@ -0,0 +1,364 @@
+var sys = require('sys'),%0A%09graphviz = require('../lib/graphviz');%0A%0A// Create digraph G%0Avar g = graphviz.digraph(%22G%22);%0Ag.set( %22splines%22, %22compound%22);%0Ag.from( %22A%22 ).to( %22B%22 ).to( %22F%22 );%0Ag.from( %22A%22 ).to( %22C%22 ).to( %22D%22 ).to( %22F%22 );%0Ag.from( %22A%2... | |
df9cd9eb84193d5d7fd4e297c502e54182cf654c | Update js/jquery.stickytableheaders.js | js/jquery.stickytableheaders.js | js/jquery.stickytableheaders.js | /*! Copyright (c) 2011 by Jonas Mosbech - https://github.com/jmosbech/StickyTableHeaders
MIT license info: https://github.com/jmosbech/StickyTableHeaders/blob/master/license.txt */
(function ($) {
$.StickyTableHeaders = function (el, options) {
// To avoid scope issues, use 'base' instead of 'this'
// ... | JavaScript | 0 | @@ -1278,24 +1278,46 @@
%09'top': 0,%0D%0A
+%09%09%09%09%09'z-index':99999%0D%0A
%09%09%09%09%09'left':
|
7f91a82cb1ca8d249fcbff77cbb41f0f4efd216b | Create canvasjs.min.js | js/canvasjs.min.js | js/canvasjs.min.js | JavaScript | 0.000005 | @@ -0,0 +1 @@
+%0A
| |
7e99b1d39486804d5f098d07146eeef2d9632186 | Add benchmarks | lib/node_modules/@stdlib/math/base/special/trunc10/benchmark/benchmark.js | lib/node_modules/@stdlib/math/base/special/trunc10/benchmark/benchmark.js | JavaScript | 0.00001 | @@ -0,0 +1,633 @@
+'use strict';%0A%0A// MODULES //%0A%0Avar bench = require( '@stdlib/bench' );%0Avar randu = require( '@stdlib/math/base/random/randu' );%0Avar isnan = require( '@stdlib/math/base/utils/is-nan' );%0Avar pkg = require( './../package.json' ).name;%0Avar trunc10 = require( './../lib' );%0A%0A%0A// MAIN /... | |
dfacccbedb6df69b7632741cc06645e314c92c13 | Add Karma-test | karma-test-shim.js | karma-test-shim.js | JavaScript | 0.000001 | @@ -0,0 +1,1382 @@
+// /*global jasmine, __karma__, window*/%0AError.stackTraceLimit = Infinity;%0Ajasmine.DEFAULT_TIMEOUT_INTERVAL = 1000;%0A%0A__karma__.loaded = function () %7B%0A%7D;%0A%0Afunction isJsFile(path) %7B%0A return path.slice(-3) == '.js';%0A%7D%0A%0Afunction isSpecFile(path) %7B%0A return /%5C.spec%5C... | |
45755727f07597c2a48ecea092c1fb1335862ce0 | add test for binary decodeToString without parameter | test/js/binary.js | test/js/binary.js | JavaScript | 0.000002 | @@ -0,0 +1,270 @@
+const binary = require('binary');%0Aconst asserts = require('test').asserts;%0A%0Aif (!this.exports) this.exports = %7B%7D;%0A%0Aexports.test_decodeToString = function() %7B%0A%09b = binary.ByteString(%5B65, 66%5D);%0A%09asserts.same(b.decodeToString(), %22AB%22);%09%0A%7D%0A%0Arequire('test').runner... | |
6f096238e6645355c00132bfe3ec062bdb560d67 | test commit 2 | zoffob_test.js | zoffob_test.js | JavaScript | 0.000001 | @@ -0,0 +1,6 @@
+mnauuu
| |
c2b6af340d8dc6e39ba6fb6c2f3b5660460c65be | Add size tests | test/size-test.js | test/size-test.js | JavaScript | 0.000001 | @@ -0,0 +1,2189 @@
+'use strict';%0A%0Aconst expect = require('chai').expect,%0A Redis = require('ioredis'),%0A ObjectStore = require('../index');%0A%0Alet redisClient = new Redis(%7B%0A db: 15%0A%7D);%0A%0Alet store;%0Alet id;%0A%0Adescribe('Size', function() %7B%0A beforeEach(function() %7B%0A ... | |
977c2933beea89e79bcd4a7a2181899b1237b79b | Create mimage.jquery.js | mimage.jquery.js | mimage.jquery.js | JavaScript | 0.000003 | @@ -0,0 +1,943 @@
+%7B%0A %22name%22: %22mimage%22,%0A %22title%22: %22jQuery Multisource Image%22,%0A %22description%22: %22jQuery plugin for mediaquery-like using of multiple images sources. Short & clear implementation of the idea of the %3Cpicture%3E element.%22,%0A %22keywords%22: %5B%0A %22imag... | |
a90e37084ba71392036aaaeb913805df82c133cd | Add benchmarks | lib/node_modules/@stdlib/math/base/random/negative-binomial/benchmark/benchmark.js | lib/node_modules/@stdlib/math/base/random/negative-binomial/benchmark/benchmark.js | JavaScript | 0.00001 | @@ -0,0 +1,1258 @@
+'use strict';%0A%0A// MODULES //%0A%0Avar bench = require( '@stdlib/bench' );%0Avar randu = require( '@stdlib/math/base/random/randu' );%0Avar ceil = require( '@stdlib/math/base/special/ceil' );%0Avar isnan = require( '@stdlib/math/base/utils/is-nan' );%0Avar EPS = require( '@stdlib/math/constants/f... | |
3c3f454c597e955c3200d9816e8d0f7dea22513c | Update version of mobile to 0.1.3 | mobile-config.js | mobile-config.js | // This section sets up some basic app metadata,
// the entire section is optional.
App.info({
id: 'com.konecty.rocket.chat',
version: '0.0.2',
name: 'Rocket.Chat',
description: 'Rocket.Chat',
author: 'Rocket.Chat Development Group',
email: 'contact@rocket.chat',
website: 'https://rocket.chat'
});
// Set up res... | JavaScript | 0 | @@ -137,11 +137,11 @@
'0.
-0.2
+1.3
',%0A%09
|
3bf33cc86bb7a7b569198abfbb320ada2e127590 | Remove debug | modules/names.js | modules/names.js | var h = require('hyperscript')
var pull = require('pull-stream')
function all(stream, cb) {
pull(stream, pull.collect(cb))
}
var plugs = require('../plugs')
var getAvatar = require('ssb-avatar')
var sbot_links2 = plugs.first(exports.sbot_links2 = [])
var sbot_links = plugs.first(exports.sbot_links = [])
var sbot_wh... | JavaScript | 0.000001 | @@ -1431,42 +1431,8 @@
rr)%0A
- console.log(avatar)%0A
|
e740c644f51d51395e3a0836e584a41b8b786f18 | trim whitespace | modules/split.js | modules/split.js | var h = require('hyperscript')
var screen_view =
require('../plugs').first(exports._screen_view = [])
exports.screen_view = function (path) {
var m = /^split\s*\((.*)\)$/.exec(path)
if(!m)
return
return h('div.row',
m[1].split(',').map(function (e) {
return screen_view(e)
}).filter(Boolean... | JavaScript | 0.000091 | @@ -290,16 +290,23 @@
n_view(e
+.trim()
)%0A %7D)
|
def4b6755195bade9171916e8d283738bc2e6058 | Create autoroute.es6 | autoroute.es6 | autoroute.es6 | JavaScript | 0.000001 | @@ -0,0 +1,759 @@
+var route = %7B%7D%0A%0Aroute.create = function (path, element, next) %7B%0A%0A var w = window%0A var l = w.location%0A l.hash == '' ? l.hash = '/' :%0A%0A w.addEventListener(%22hashchange%22, function () %7B%0A%0A var e = document.querySelectorAll(element)%5B0%5D%0A%0A function clear () %7... | |
7e46fee090ae9737f91d93683bf52d37b5dbd1fb | add 2015_Round1A_A.js | 2015_Round1A_A.js | 2015_Round1A_A.js | JavaScript | 0.000002 | @@ -0,0 +1,1013 @@
+var codejam = require('./lib/codejam');%0A%0Afunction computeMethod1(cakes) %7B%0A var lastCake;%0A return cakes.reduce(function(memo, cake) %7B%0A if (lastCake !== void 0) %7B%0A if (cake %3C lastCake) %7B%0A memo += (lastCake - cake);%0A %7D%0A %7D%0A lastCake = cake;%0... | |
fb611701848888f33b5c116015877d7145bc09b8 | add fuzzy module | AI/FuzzyModule.js | AI/FuzzyModule.js | JavaScript | 0.000001 | @@ -0,0 +1,951 @@
+var FuzzyTriangleSet = require(%22./FuzzyTriangleSet%22);%0Avar FuzzyLeftShoulderSet = require(%22./FuzzyLeftShoulderSet%22);%0Avar FuzzyRightShoulderSet = require(%22./FuzzyRightShoulderSet%22);%0Avar FuzzyVariable = require(%22./FuzzyVariable%22);%0Avar FuzzyRule = require(%22./FuzzyRule%22);%0Avar... | |
7955ebd80c4c6d1aac6d794a6120eadd0cbbedd8 | implement create-type-proxies script | scripts/create-type-proxies.js | scripts/create-type-proxies.js | JavaScript | 0.00001 | @@ -0,0 +1,364 @@
+#!/usr/bin/env node%0A%0Aconst %7B writeFile, pkgDir %7D = require(%22./lib%22);%0A%0Aconst createProxy = async (module) =%3E %7B%0A await writeFile(%0A pkgDir(module, %22dist%22, %22main.d.ts%22),%0A %60export * from %22./$%7Bmodule%7D/lib/main%22%60%0A );%0A%7D;%0A%0A(async () =%3E %7B%0A ... | |
cae1ac357ef2d70941a751308481f7c0f563e9b1 | add directive from gist | pf-mobilePolyForm.js | pf-mobilePolyForm.js | JavaScript | 0.000001 | @@ -0,0 +1,3129 @@
+/*global ionic*/%0A%0A// for example usage, see http://codepen.io/premiumfrye/pen/pJMOZe%0Aangular.module('pf-mobilePolyForm')%0A .directive('mobileFormPolyfill', function ($timeout, $parse) %7B%0A // keep track of our input fields for jumping to the next%0A var inputs = %5B%5D,%0A // any ... | |
84c04f3f88a2ef17341743d8d22da737649afca4 | Create background.js | background.js | background.js | JavaScript | 0 | @@ -0,0 +1,1466 @@
+%0Afunction searchyahoofinance(info)%0A%7B%0A var searchurl = info.linkUrl;%0A var n1 = searchurl.indexOf(%22%253A%22) + 3;%0A var n2 = searchurl.indexOf(%22&%22);%0A var n3 = searchurl.indexOf(%22www.google.com/finance%22);%0A var ticker = searchurl.substring(... | |
033c1c777838931051cc244aee0724cfb97dbda4 | add tests, #421 | test/client/no-results.clienttest.js | test/client/no-results.clienttest.js | JavaScript | 0 | @@ -0,0 +1,321 @@
+module.exports = %7B%0A 'Display list view on search page': function (browser) %7B%0A browser%0A .url('http://localhost:8000/search?q=noooooooresults')%0A .waitForElementVisible('body', 1000)%0A .assert.elementNotPresent('.control__buttons')%0A .assert.elementNotPresent('.cont... | |
febbc8c4780d0e67d5880b471f68d3dfdd2ebc84 | add inline doc for background | background.js | background.js |
// scopes need to be cached here so that if the devtools connects,
// the list of scopes can be immediately populated
// TODO: clear this on refresh ?
var scopeCache = {};
var scopeCacheEmpty = function () {
return Object.keys(scopeCache).length;
};
// messages to be forwarded from content script to the devtools
v... | JavaScript | 0.000001 | @@ -145,16 +145,63 @@
fresh ?%0A
+// appId --%3E %7B scopeName --%3E (key, value...) %7D%0A
var scop
|
ec05b8fd74086ad3b0fa12adea6858d232cbd97e | Fix ESLint failure | web/js/base.js | web/js/base.js | $(document).ready(function() {
var hideMenuButton = function(transition) {
$('#links-top').slideToggle(transition, function(){
if ($('#links-top').is(':visible')) {
$('#links-top-button').attr('title', 'Hide Transvision Menu');
$('#links-top-button').css('backgrou... | JavaScript | 0.000171 | @@ -1805,33 +1805,16 @@
locale%7D)
-%0A
.text(lo
|
596a83039ea7c266e094925080c73080b4460d7e | Add DataAcquisitionProjectResource test | src/test/javascript/spec/dataacquisitionprojectmanagement/resources/dataAcquisitionProject.spec.js | src/test/javascript/spec/dataacquisitionprojectmanagement/resources/dataAcquisitionProject.spec.js | JavaScript | 0 | @@ -0,0 +1,812 @@
+/* global describe */%0A/* global beforeEach */%0A/* global it */%0A/* global inject */%0A/* global expect */%0A/* global mockApis */%0A%0A'use strict';%0A%0Adescribe('DataAcquisitionProject', function() %7B%0A%09var mockDataSetResource;%0A%09var $httpBackend;%0A%09var data = %7B%0A%09%09id: 1,%0A%09... | |
ad0e497317cd30999caa9fe3e1cddd7f17c100a0 | Remove saveHandler and fileClient from AbstractEditor. | ui/AbstractEditor.js | ui/AbstractEditor.js | import Component from './Component'
import CommandManager from './CommandManager'
import SurfaceManager from './SurfaceManager'
import MacroManager from './MacroManager'
import GlobalEventHandler from './GlobalEventHandler'
import DragManager from './DragManager'
class AbstractEditor extends Component {
constructor... | JavaScript | 0 | @@ -1983,119 +1983,8 @@
t()%0A
- this.saveHandler = configurator.getSaveHandler()%0A this.documentSession.setSaveHandler(this.saveHandler)%0A
@@ -2156,59 +2156,8 @@
on)%0A
- this.fileClient = configurator.getFileClient()%0A
@@ -3007,80 +3007,8 @@
er,%0A
- fileClient: this.fileClient,%0A ... |
7154c5e376ad257a0601152b104609f784abcc03 | Create backbone.grouped-collection.js | backbone.grouped-collection.js | backbone.grouped-collection.js | JavaScript | 0.000003 | @@ -0,0 +1,2326 @@
+(function () %7B%0A%0A var collection_proto;%0A%0A collection_proto = %7B%0A closeWith: function (view) %7B%0A view.on('close', this.stopListening);%0A %7D%0A %7D;%0A%0A%0A /**%0A * Creates a Group model for a given id.%0A * Context is the options object%0A *%0A * @param %7BSt... | |
e606304f9d074c8541aa45e376bb6cf3cc14137a | Add reducer test for ENHANCE_CAN_DROP_PIECE. | test/reducers/shogi/enhanceCanDropPosition_test.js | test/reducers/shogi/enhanceCanDropPosition_test.js | JavaScript | 0 | @@ -0,0 +1,2038 @@
+import shogi from '../../../frontend/reducers/shogi';%0Aimport * as Action from '../../../frontend/actions';%0Aimport Piece from '../../../frontend/src/shogi/piece';%0Aimport Board from '../../../frontend/src/shogi/board';%0Aimport memo from 'memo-is';%0A%0Adescribe('shogi', () =%3E %7B%0A describe... | |
f99b4a72a5871b49dd95fa41bdf66ada81912e7e | Add input plugin test. - client plugin added. | test/plugin/in/client_test.js | test/plugin/in/client_test.js | JavaScript | 0 | @@ -0,0 +1,1180 @@
+var client = require('../../../lib/plugin/in/client.js'),%0A nock = require('nock'),%0A here = require('here').here;%0A%0Adescribe('input plugin: client', function()%7B%0A var mockApiUrl = %22http://test.com/json%22;%0A%0A beforeEach(function(done) %7B%0A var testJsonApiResponse = here(/*... | |
86245ef4630ef25026bb69422c9008d1d2ce2b0c | Add spec for helpers | lib/assets/test/spec/builder/editor/style/style-form/style-form-helpers.spec.js | lib/assets/test/spec/builder/editor/style/style-form/style-form-helpers.spec.js | JavaScript | 0 | @@ -0,0 +1,2688 @@
+// var Backbone = require('backbone');%0Avar getQuerySchemaModelFixture = require('fixtures/builder/query-schema-model.fixture.js');%0A// var getConfigModelFixture = require('fixtures/builder/config-model.fixture.js');%0A%0A// var StyleModel = require('builder/editor/style/style-definition-model.js'... | |
c70cab4a7a50324d7e3074fff8f8d764285ccfea | Use receiver and giver terminology for hashes | src/working-copy.js | src/working-copy.js | var fs = require("fs");
var nodePath = require("path");
var index = require("./index");
var files = require("./files");
var objects = require("./objects");
var refs = require("./refs");
var diff = require("./diff");
var util = require("./util");
var workingCopy = module.exports = {
writeCheckout: function(fromHash, ... | JavaScript | 0 | @@ -307,20 +307,27 @@
ion(
-from
+receiver
Hash,
-to
+giver
Hash
@@ -384,18 +384,50 @@
Toc(
-fromHash),
+receiverHash),%0A
obj
@@ -445,18 +445,21 @@
mmitToc(
-to
+giver
Hash));%0A
@@ -825,10 +825,13 @@
er,
-to
+giver
Hash
|
e2f080a3c4b768923e3849ca593c5c8004c697b4 | Create eFor.js | eFor.js | eFor.js | JavaScript | 0 | @@ -0,0 +1,596 @@
+function eForStep(arr, arrLen, i, callback) %7B%0A if (i %3C arrLen) %7B%0A let item = arr%5Bi%5D;%0A callback(item);%0A setTimeout(eForStep.bind(this, arr, arrLen, i + 1, callback));%0A %7D%0A%7D%0A/**%0A * For statement emulation to work with large arrays without event lo... | |
0753ae020019b14c9cc0e92c7056adeaaf41328b | Remove focus from autotranslation test | test/tests/autotranslation.js | test/tests/autotranslation.js | var BeakerPageObject = require('./beaker.po.js');
var path = require('path');
fdescribe('autotranslation', function() {
beforeEach(function() {
jasmine.DEFAULT_TIMEOUT_INTERVAL = 120000; // Slow initialization cells, CI box might need a long time to initialize these
beakerPO = new BeakerPageObject();
bro... | JavaScript | 0 | @@ -72,17 +72,16 @@
ath');%0A%0A
-f
describe
|
b202e3f111e4387f75ca35a902d1587f0b9bf91f | add stylelint config 🥳 | stylelint.config.js | stylelint.config.js | JavaScript | 0 | @@ -0,0 +1,190 @@
+module.exports = %7B%0A extends: %5B'stylelint-config-standard', 'stylelint-config-prettier'%5D,%0A // add your custom config here%0A // https://stylelint.io/user-guide/configuration%0A rules: %7B%7D,%0A%7D;%0A
| |
f2bbfa70d691cbf90004eab0984b5f35481a8be8 | add unit tests | app/stats/stats.spec.js | app/stats/stats.spec.js | JavaScript | 0 | @@ -0,0 +1,1148 @@
+describe('StatsController', function () %7B%0A beforeEach(function () %7B%0A module('antismash.db.ui.stats');%0A %7D);%0A%0A var $httpBackend;%0A var createController;%0A var ctrl;%0A%0A beforeEach(function () %7B%0A inject(function ($injector) %7B%0A%0A var $controller = $injector.... | |
3c18d2da9f903e0875ba83a1aeb42d12940d4eba | remove unnecessary escapes | app/assets/javascripts/components/physical_infrastructures/change-password-component.js | app/assets/javascripts/components/physical_infrastructures/change-password-component.js | (function() {
ManageIQ.angular.app.component('changePasswordComponent', {
bindings: {
recordId: '@?',
recordName: '@?',
redirectUrl: '@',
},
controllerAs: 'vm',
controller: changePasswordFormController,
templateUrl: '/static/ems_physical_infra/change_password.html.haml',
});
... | JavaScript | 0.000001 | @@ -712,21 +712,19 @@
the %25s
-%5C
%22%25s
-%5C
%22.'), vm
@@ -1364,13 +1364,11 @@
%25s
-%5C
%22%25s
-%5C
%22 wa
|
74fcbee17bd99b0586a155b0794f561428181660 | Add template json schema test | test/config/templates-schema.js | test/config/templates-schema.js | JavaScript | 0 | @@ -0,0 +1,824 @@
+const fs = require('fs');%0Aconst path = require('path');%0Aconst jsYaml = require('js-yaml');%0Aconst should = require('should');%0A// eslint-disable-next-line no-unused-vars%0Aconst Config = require('../../lib/config');%0Aconst schema = require('../../lib/schemas');%0A%0Adescribe('EG templates sche... | |
d0cb2ce803df6708ea2694c5b885a1b9287eef14 | Add Stack Overflow to the support page | website/src/relay/support.js | website/src/relay/support.js | /**
* Copyright (c) 2015-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 patent rights can be found in the PATENTS file in the same directory.
*/
var React ... | JavaScript | 0 | @@ -934,24 +934,412 @@
%3C/p%3E%0A%0A
+ %3CH2%3EStack Overflow%3C/H2%3E%0A %3Cp%3EMany members of the community use Stack Overflow to ask questions. Read through the %3Ca href=%22https://stackoverflow.com/questions/tagged/reactjs?sort=active%22 rel=%22nofollow%22%3Eexisting questions%3C/a%3... |
48f0105900ea81f968a65c5b028b5876974ded32 | Add FLoC API interface to externs. See https://wicg.github.io/floc for API details. | externs/browser/wicg_floc.js | externs/browser/wicg_floc.js | JavaScript | 0 | @@ -0,0 +1,842 @@
+/*%0A * Copyright 2008 The Closure Compiler Authors%0A *%0A * Licensed under the Apache License, Version 2.0 (the %22License%22);%0A * you may not use this file except in compliance with the License.%0A * You may obtain a copy of the License at%0A *%0A * http://www.apache.org/licenses/LICENSE-2.0... | |
8cef34add0bbe730f4046faa9616aa99533bbe23 | Add test for bitwise hash | test/BitwiseHash.js | test/BitwiseHash.js | JavaScript | 0.000001 | @@ -0,0 +1,817 @@
+var assert = require('assert'),%0A BitwiseHash = require('./../lib/BitwiseHash');%0A%0Adescribe('BitwiseHash', function () %7B%0A it('Should create instance', function () %7B%0A var hash = new BitwiseHash('some data');%0A assert(hash instanceof BitwiseHash, 'Should be instance of ... | |
8c6787600538fb9a22583b9f562222e35f96e8cd | add utils folder (extend _), add capitalizeFirstLetter | client/_utils/utils.strings.js | client/_utils/utils.strings.js | JavaScript | 0.000001 | @@ -0,0 +1,98 @@
+_.capitalizeFirstLetter = function(str) %7B%0A return str.charAt(0).toUpperCase() + str.slice(1);%0A%7D;%0A
| |
0e578da0a6696e57e02bf267ce7de7f17467be9c | create JS file for form submit logic. | client/templates/create_bet.js | client/templates/create_bet.js | JavaScript | 0 | @@ -0,0 +1,499 @@
+Template.createBetForm.events(%7B%0A %22submit .create-bet%22: function(event) %7B%0A var status = %22open%22;%0A var title = event.target.betTitle.value;%0A var wager = event.target.betWager.value;%0A var user = Meteor.user();%0A%0A var d_username = event.target.defender.value;%0A ... | |
a74830b8f9efbf27e5cce45c654c0fdc8c647de2 | add max leng directive | 2.5.2/vue.extension.maxlen.js | 2.5.2/vue.extension.maxlen.js | JavaScript | 0.000017 | @@ -0,0 +1,524 @@
+/**%0A * Created by kaicui on 2018%E5%B9%B403%E6%9C%8819%E6%97%A5%0A * 1%E3%80%81%E4%BD%BF%E7%94%A8v-max-len=%22some number%22 %E8%BF%9B%E8%A1%8C%E7%BB%91%E5%AE%9A%0A *%0A * 2018%E5%B9%B403%E6%9C%8819%E6%97%A5%EF%BC%9A%E6%94%B9%E5%86%99%E4%B8%BA%E9%80%82%E5%90%882.5.2+%E7%89%88%E6%9C%AC%E7%9A%84vue%0... | |
bf54dd91c63a1aa0b6953af165bf0e77dacedce4 | Create asana-in-bitbucket.js | scripts/asana-in-bitbucket.js | scripts/asana-in-bitbucket.js | JavaScript | 0.000003 | @@ -0,0 +1,969 @@
+// ==UserScript==%0A// @name Asana Links in Bitbucket%0A// @namespace http://tampermonkey.net/%0A// @version 0.1%0A// @description Use Asana Task Id and render as links in Bitbucket%0A// @author Lukas Siemon%0A// @match https://bitbucket.org/*%0A// @grant none%0A/... | |
cd318fb75a0a385962742d281350d393fff9a4f1 | Add MediaStream Test | test/mediaStream.js | test/mediaStream.js | JavaScript | 0 | @@ -0,0 +1,2683 @@
+var WEBRTC = require('../');%0A%0Avar config = %7B%0A iceServers: %5B%0A %7B%0A url: 'stun:stun.l.google.com:19302',%0A %7D,%0A %5D,%0A%7D;%0A%0Avar constraints = %7B%0A audio: true,%0A video: true,%0A optional: %5B%0A %7B%0A DtlsSrtpKeyAgreement: true,%0A %7D,%0A %5D,%0A... | |
788ceb61427474ab3333ccc7fcd4193c5109a93d | test for the limit to work when a regexp is used in the query | test/regex-limit.js | test/regex-limit.js | JavaScript | 0.000001 | @@ -0,0 +1,1038 @@
+var level = require('level-test')()%0Avar sub = require('level-sublevel');%0A%0Avar tape = require('tape')%0Avar search = require('../');%0A%0Avar db = sub(level('level-search--regex-end-event', %7Bencoding: 'json'%7D))%0Avar index = search(db, 'index');%0Avar values = Math.pow(26, 3);%0A%0At... | |
c1320765b48329084a9fe632b671b6bfedc6d0ae | Add sceleton for client unittest | test/test_client.js | test/test_client.js | JavaScript | 0 | @@ -0,0 +1,50 @@
+'use strict';%0A%0Aconst assert = require('assert');%0A%0A
| |
da4ad8f22b3155f17ffee2a1f292dc9818691a9f | Create app.js | scripts/app.js | scripts/app.js | JavaScript | 0.000003 | @@ -0,0 +1,423 @@
+'use strict';%0A%0A/**%0A * @ngdoc overview%0A * @name clientApp%0A * @description%0A * # clientApp%0A *%0A * Main module of the application.%0A */%0Aangular%0A .module('myapp', %5B%0A 'ngRoute'%0A %5D)%0A .config(function ($routeProvider) %7B%0A $routeProvider%0A .when('/', %7B%0A ... | |
656cefa830ff0771643019dd1ee9aec53921d4e5 | Add Mask 'm' Tests | test/test_mask-m.js | test/test_mask-m.js | JavaScript | 0.000037 | @@ -0,0 +1,859 @@
+var assert = require(%22assert%22);%0Avar dateFormat = require(%22../lib/dateformat%22);%0A%0Adescribe(%22Mask: 'm'%22, function () %7B%0A it(%22should format '1974-02-7' as '2'%22, function (done) %7B%0A let date = new Date(%221974-02-7%22);%0A var d = dateFormat(date, %22m%22);%0A assert.... | |
704859e46397043b238a3f5769d56b4fa94b4010 | Create sendMessage.js | sendMessage.js | sendMessage.js | JavaScript | 0.000001 | @@ -0,0 +1,675 @@
+//sendMessage.js%0A%0A// const ACC_SID = %22Enter Account SID%22;%0A// const AUTH_TOKEN = %22Enter Authentication Token%22;%0A// const TWILIO_NUMBER = %22Enter Twilio Number%22;%0A%0Avar client = require ('twilio') (ACC_SID, AUTH_TOKEN);%0Avar readLine = require ('readline');%0A%0Avar r1 = readLine.c... | |
27e24303ccde1b8f446f2ec7ea22f2fa92b15331 | Test the import | tests/index.test.js | tests/index.test.js | JavaScript | 0.000013 | @@ -0,0 +1,148 @@
+describe('Test the index.js', () =%3E %7B %0A test('should import VeasyForm', () =%3E %7B %0A const VeasyForm = require('../src/index').default;%0A %7D);%0A%7D);
| |
1857e39865a9e29babde342b4fea91994e598d6e | Add solution to Day 10a | 10.js | 10.js | JavaScript | 0.000027 | @@ -0,0 +1,2284 @@
+require('./helpers').getFile(10, input =%3E %7B%0A const agents = %7B%7D;%0A%0A function init(id, type) %7B%0A const i = %60$%7Bid%7D-$%7Btype%7D%60;%0A if (!agents%5Bi%5D) %7B agents%5Bi%5D = %7B id, type, rules: %5B%5D, values: %5B%5D, matches: %5B%5D %7D; %7D%0A %7D%0A%0A input.split('%... | |
fc37fb95fbbf27eff75044891b5e21e61977a0fe | Add default newrelic.js, config is overriden in env variables | newrelic.js | newrelic.js | JavaScript | 0.000001 | @@ -0,0 +1,622 @@
+/**%0A * New Relic agent configuration.%0A *%0A * See lib/config.defaults.js in the agent distribution for a more complete%0A * description of configuration variables and their potential values.%0A */%0Aexports.config = %7B%0A /**%0A * Array of application names.%0A */%0A app_name : %5B'My Appl... | |
92393f7dd6d21fa05b02cb86704f8b45d57b092e | Create example.js | example/example.js | example/example.js | JavaScript | 0.000001 | @@ -0,0 +1,386 @@
+ function pInput() %7B%0A var input = document.getElementById(%22cInput%22).value;%0A var parsed = vas(input);%0A var output = %22%22;%0A for (var i in parsed) %7B%0A output += String(i) + %22 : %5Cn%22;%0A output += %22%5Ctvalue : %22 + parsed%5Bi%5D%5B%22value%22%5D ... | |
facb0afe5f5c95e8826026a233796b2b988e7dbf | Use -c or --config to specify the location of the configuration file in the binary version. | bin/superstatic.js | bin/superstatic.js | #!/usr/bin/env node
var spawn = require('child_process').spawn;
var path = require('path');
var argv = require('optimist').argv;
var gaze = require('gaze');
var colors = require('colors');
var Superstatic = require('../lib/server/superstatic_server');
var defaults = require('../lib/defaults');
// app working director... | JavaScript | 0 | @@ -1202,52 +1202,34 @@
le:
-'superstatic.json', // TODO: change to use %5B
+(argv.c %7C%7C argv.config %7C%7C
'sup
@@ -1246,25 +1246,10 @@
son'
+)
,
- 'divshot.json'%5D
%0A
|
857074e686676082eccadd80089a199fad25fd14 | Handle errors for config file that doesn't exist | bin/superstatic.js | bin/superstatic.js | #!/usr/bin/env node
require('colors');
var path = require('path');
var chokidar = require('chokidar');
var argv = require('optimist').argv;
var Superstatic = require('../lib/server/superstatic_server');
var defaults = require('../lib/defaults');
var server;
// app working directory
var port = exports.port = argv.po... | JavaScript | 0 | @@ -237,24 +237,79 @@
defaults');%0A
+var ConfigFile = require('../lib/server/config/file');%0A
var server;%0A
@@ -645,16 +645,25 @@
on () %7B%0A
+ try%7B%0A
chokid
@@ -712,16 +712,18 @@
())%0A
+
.on('cha
@@ -748,16 +748,35 @@
anged);%0A
+ %7D%0A catch (e) %7B%7D%0A
%7D);%0A%0Afun
|
5abb9a8f8cd0740283651cf4b306ca45a06f17f7 | Add mathjs example | examples/mathjs.js | examples/mathjs.js | JavaScript | 0.000007 | @@ -0,0 +1,411 @@
+//%0A// In order to run this example, you'll need to run:%0A// $ npm install mathjs%0A//%0A%0Avar mathjs = require('mathjs');%0Avar integrate = require('../');%0Avar parser = mathjs.parser();%0A%0Aparser.eval('f(x) = cos(1/x)/x');%0Avar value = integrate(parser.get('f'), 0.01, 1, 0.001);%0A%0Aconsole... | |
3ae5f213234619165943f5b8ff0e5c0446504b00 | Create mag-transitions.js | src/addons/mag-transitions.js | src/addons/mag-transitions.js | JavaScript | 0 | @@ -0,0 +1,1825 @@
+/*%0AName: mag-transitions v0.1.0%0ADescription: animate mag modules easily based on react-css-transition-group (https://github.com/react-component/css-transition-group)%0AExample: reusable modal with css transitions (https://github.com/tryolabs/react-examples/tree/master/modal)%0AAuthor: Michael Gl... | |
d635f976fbf934a5d51870f0d3e658c81d7d1ab8 | Add style-checkbox.js | js/modules/style-checkbox.js | js/modules/style-checkbox.js | JavaScript | 0 | @@ -0,0 +1,1252 @@
+define(function(require) %7B%0A%0A var clazz = require('modules/clazz');%0A var evt = require('modules/dom-events');%0A%0A var defaults = %7B%0A className: 'scheckbox',%0A checkedClassName: 'scheckbox-checked',%0A focusedClassName: 'scheckbox-focused'%0A %7D;%0A%0A function initCheckbo... | |
93794e5db25e9bc2919314fae2732ba35d225e99 | Add Tailwind config file | tailwind.config.js | tailwind.config.js | JavaScript | 0 | @@ -0,0 +1,175 @@
+module.exports = %7B%0A purge: %5B%0A './source/**/*.erb',%0A './source/**/*.scss',%0A './source/**/*.js',%0A %5D,%0A theme: %7B%0A extend: %7B%7D,%0A %7D,%0A variants: %7B%7D,%0A plugins: %5B%5D,%0A%7D%0A
| |
a24c21897923d899889ed1c93aa1927533a4f966 | Add custom newline tests | lib/node_modules/@stdlib/utils/dsv/base/parse/test/test.custom_newline.js | lib/node_modules/@stdlib/utils/dsv/base/parse/test/test.custom_newline.js | JavaScript | 0 | @@ -0,0 +1,1474 @@
+/**%0A* @license Apache-2.0%0A*%0A* Copyright (c) 2022 The Stdlib Authors.%0A*%0A* Licensed under the Apache License, Version 2.0 (the %22License%22);%0A* you may not use this file except in compliance with the License.%0A* You may obtain a copy of the License at%0A*%0A* http://www.apache.org/lic... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.