conversations listlengths 2 3 | source stringclasses 1
value | stack stringclasses 1
value |
|---|---|---|
[
{
"from": "system",
"value": "Fix from email in POST route test email\n"
},
{
"from": "human",
"value": "import { Meteor } from 'meteor/meteor';\nimport { Accounts } from 'meteor/accounts-base';\nimport { Email } from 'meteor/email';\n\nconst Post = Picker.filter((req, res) => (req.method === 'P... | javascript | chosen |
[
{
"from": "system",
"value": "Fix jumping on ref removing.\n"
},
{
"from": "human",
"value": "import { Component } from 'substance'\n\n/*\n Simplistic back-matter displaying references and appendixes\n*/\nexport default class BackComponent extends Component {\n\n render($$) {\n const node =... | javascript | chosen |
[
{
"from": "system",
"value": "Deal with call from local script.\n"
},
{
"from": "human",
"value": "// Find the GitHub branch we are running from\ngetBranch = function (path, repository) {\n // The branch is the word after the repository name, and before the word \"tests\"\n // Assumes that... | javascript | chosen |
[
{
"from": "system",
"value": "Change default state of howitworks visibility\n"
},
{
"from": "human",
"value": "import { createStore, applyMiddleware, compose } from 'redux'\nimport { routerMiddleware } from 'react-router-redux'\nimport promiseMiddleware from 'redux-promise-middleware'\nimport cr... | javascript | chosen |
[
{
"from": "system",
"value": "Add sollution to sum all\n"
},
{
"from": "human",
"value": "function sumAll(arr) {\n var total = 0;\n var len = arr.length;\n \n for(var i = 0; i <= len;i++){\n total += arr[i];\n }\n return total;\n}\n\nsumAll([1, 4]);\n"
},
{
"from": "gpt",
"v... | javascript | chosen |
[
{
"from": "system",
"value": "Fix chart no data display\n"
},
{
"from": "human",
"value": "var merge = require('merge');\n\nvar temperature = require('../model/temperature.js');\nvar humidity = require('../model/humidity.js');\nvar gas = require('../model/gas.js');\nvar co = require('../model/co... | javascript | chosen |
[
{
"from": "system",
"value": "Change initial state of error.\n"
},
{
"from": "human",
"value": "module.exports = {\n selectedItem: 1,\n budgetItems: [],\n error: {\n show: true,\n text: 'Hello my name is nathan'\n }\n}\n"
},
{
"from": "gpt",
"value": "module.exports = {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Rename (and improve) message collection and schema to cards\n"
},
{
"from": "human",
"value": "\"use strict\";\n\nNbsp.Messages = new Mongo.Collection(\"rooms\");\n\nNbsp.MessageSchema = new SimpleSchema({\n from: {\n type: String,\n label: \"Your name\",\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Allow starting of long test tasks in client\n\n"
},
{
"from": "human",
"value": "/**\n *\n *\n * @copyright 2017 Government of Canada\n * @license MIT\n * @author igboyes\n *\n */\n\nimport Request from \"superagent\";\n\nconst jobsAPI = {\n\n find: () => {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Change media query breakpoint of overDesktop on about-us page\n"
},
{
"from": "human",
"value": "const sm = 576\nconst md = 768\nconst lg = 1024\nconst xl = 1440\nexport default {\n smallScreenMinWidth: sm,\n smallScreenMaxWidth: md - 1,\n mediumScreenMaxWidth: l... | javascript | chosen |
[
{
"from": "system",
"value": "Remove obsolete specs for keyCapture service\n"
},
{
"from": "human",
"value": "\"use strict\";\n\ndescribe('keyCapture', function() {\n beforeEach(module('arethusa.core'));\n\n describe('isCtrlActive', function() {\n it('return false before any event', inject(... | javascript | chosen |
[
{
"from": "system",
"value": "[DOTS-CONNECT] Fix passing scene to game\n"
},
{
"from": "human",
"value": "\"use strict\";\nvar playfield;\nvar scene;\nvar game;\n\nfunction init() {\n\tplayfield = document.getElementById('playfield');\n game = new Game();\n scene = new Gamefield(initSceneC... | javascript | chosen |
[
{
"from": "system",
"value": "Use Idy to create ids\n"
},
{
"from": "human",
"value": "var Deffy = require(\"deffy\")\n , Enny = require(\"enny\")\n , Parsers = require(\"../parsers\")\n ;\n\nfunction Line(input) {\n this.source = input.source;\n this.target = input.target;\n this.id... | javascript | chosen |
[
{
"from": "system",
"value": "Improve context menu event handling\n"
},
{
"from": "human",
"value": "(function() {\n\n var wicketsource, menu;\n\n menu = chrome.contextMenus.create({\n title: \"Wicket Source\",\n contexts: [\"all\"],\n onclick: function (info) {\n if (wicketsourc... | javascript | chosen |
[
{
"from": "system",
"value": "Clear Results for next submit\n"
},
{
"from": "human",
"value": "'use strict';\n\n// Declare app level module which depends on views, and components\n/*angular.module('myApp', [\n 'ngRoute',\n 'myApp.view1',\n 'myApp.view2',\n 'myApp.version'\n]).\nconfig(['$loc... | javascript | chosen |
[
{
"from": "system",
"value": "Set mainnet as default network and bump to 1.1.12\n"
},
{
"from": "human",
"value": "const AppConstants = {\n //Application name\n appName: 'Nano Wallet',\n\n version: 'BETA 1.1.11',\n\n //Network\n defaultNetwork: -104,\n\n // Ports\n defaultNi... | javascript | chosen |
[
{
"from": "system",
"value": "Split icons into responsive grid\n"
},
{
"from": "human",
"value": "/* eslint-disable no-unused-vars*/\nimport React, { Component, PropTypes } from 'react';\n/* eslint-enable no-unused-vars*/\n\nimport Icons from 'components/Icons/';\n\nconst IconBar = () => {\n le... | javascript | chosen |
[
{
"from": "system",
"value": "Test the delete block fn\n"
},
{
"from": "human",
"value": "/* global describe: false, expect: false, it: false, inject: false, beforeEach: false */\n'use strict';\n\ndescribe('Controller: FormDropAreaCtrl', function () {\n\n // load the controller's module\n befo... | javascript | chosen |
[
{
"from": "system",
"value": "Add JSDoc info for attachAttr\n"
},
{
"from": "human",
"value": "function attachAttr (ele, attr) {\n for (var a in attr) {\n ele.setAttribute(a, attr[a]);\n }\n return ele;\n}\n"
},
{
"from": "gpt",
"value": "/**\n * Attaches DOM attrible... | javascript | chosen |
[
{
"from": "system",
"value": "Use relative url to serve jquery\n"
},
{
"from": "human",
"value": "requirejs.config({\n paths: {\n jquery: \"/vendor/jquery\",\n }\n});\n\ndefine(['jquery'], function ($) {\n var _ = window._,\n Map = function(svg) {\n this.svg = $(svg);\n };... | javascript | chosen |
[
{
"from": "system",
"value": "Set XHR properties between open() and send()\n\nFixes IE11 compatibility. Thanks @bkonetzny for pointing it out.\n\nFixes: https://github.com/sindresorhus/public-ip/issues/16\n"
},
{
"from": "human",
"value": "'use strict';\nconst isIp = require('is-ip');\n\nconst d... | javascript | chosen |
[
{
"from": "system",
"value": "Fix conflict with test function newsfeed\n"
},
{
"from": "human",
"value": "var fs = require(\"fs\");\nvar path = require(\"path\");\nvar chai = require(\"chai\");\nvar expect = chai.expect;\nvar vm = require(\"vm\");\n\n\ndescribe(\"Functions into modules/default/c... | javascript | chosen |
[
{
"from": "system",
"value": "Fix scaling issue when a retina-capable device resizes. Will now correctly scale.\n"
},
{
"from": "human",
"value": "module.exports = function($, window, errorHandler) {\n var Multigraph = require('../../core/multigraph.js')($),\n Point = require('../../ma... | javascript | chosen |
[
{
"from": "system",
"value": "Fix stoopid mistake in log"
},
{
"from": "human",
"value": "// MIT license, see: https://github.com/tjcrowder/simple-snippets-console/blob/master/LICENSE\nvar snippet = {\n version: \"1.0\",\n\n // Writes out the given text in a monospaced paragraph tag, escap... | javascript | chosen |
[
{
"from": "system",
"value": "Fix bug issue in Settings Ctrl\n"
},
{
"from": "human",
"value": "(function() {\n var SettingsCtrl = function($scope, $ionicModal, Auth) {\n var vm = this\n\n $ionicModal\n\n .fromTemplateUrl(\"js/modules/tabs/settings/views/login.html\", {\n\n sc... | javascript | chosen |
[
{
"from": "system",
"value": "Fix minor mistake in foreignKeys\n"
},
{
"from": "human",
"value": "'use strict';\nangular.module('arethusa.core').directive('foreignKeys',[\n 'keyCapture',\n 'languageSettings',\n function (keyCapture, languageSettings) {\n return {\n restrict: 'A',\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Remove 'tab' from session array\n"
},
{
"from": "human",
"value": "// FORKED FROM https://github.com/muaz-khan/WebRTC-Experiment/tree/master/Chrome-Extensions/desktopCapture\n\n// this background script is used to invoke desktopCapture API to capture screen-MediaSt... | javascript | chosen |
[
{
"from": "system",
"value": "Apply core changes which define foreign keys to be not null by default.\n"
},
{
"from": "human",
"value": "var Model = require('chaos-orm').Model;\nvar ImageTag = require('./image-tag');\nvar Gallery = require('./gallery');\n\nclass Image extends Model {\n static _... | javascript | chosen |
[
{
"from": "system",
"value": "Return missing dev server port\n"
},
{
"from": "human",
"value": "const path = require('path');\nconst env = module.exports = {};\n\nenv.rootDir = path.join(__dirname, '..');\nenv.buildDir = path.join(env.rootDir, 'docs'); // we use docs to able publish on gh-pages\... | javascript | chosen |
[
{
"from": "system",
"value": "Change the connection url for postgres name\n"
},
{
"from": "human",
"value": "module.exports = {\n client: 'pg',\n connection: process.env.PG_URI + '?ssl=true',\n pool: {\n min: process.env.PG_POOL_MIN,\n max: process.env.PG_POOL_MAX\n },\n migrations: {... | javascript | chosen |
[
{
"from": "system",
"value": "Add test to alert for rule replacements.\n\nEslint carries forward a replacement list that indicates when a\nrule is about to be renamed/deprecated. This unit test checks our\nrules against that list, and will fail if it detects a pending\nreplacement.\n\nChange-Id: If1a20c2f6d... | javascript | chosen |
[
{
"from": "system",
"value": "Fix relative pathing of config file.\n"
},
{
"from": "human",
"value": "var filesystem = require('fs');\nvar config = { baseUrl: 'https://metrics-api.librato.com/v1/' };\ntry {\n config = JSON.parse(filesystem.readFileSync('config.json'));\n} catch (err) {\n}\n\nva... | javascript | chosen |
[
{
"from": "system",
"value": "Add flightSchema for travel demo site\n"
},
{
"from": "human",
"value": "const express = require('express');\nconst mongoose = require('mongoose');\n\n// Connect to MongoDB\nmongoose.connect('mongodb://localhost/test');\n\nconst db = mongoose.connection;\n\n// Defin... | javascript | chosen |
[
{
"from": "system",
"value": "Remove references to plugins in multiple bundles config\nIt looks like they don't need to be excluded at all.\n"
},
{
"from": "human",
"value": "// Copyright (c) 2014 Readium Foundation and/or its licensees. All rights reserved.\n//\n// Redistribution and use in s... | javascript | chosen |
[
{
"from": "system",
"value": "Fix webpack regex embed comment termination\n\nWebpack has no protection against inserting */ in the comments it writes when output.pathinfo is true"
},
{
"from": "human",
"value": "/* eslint-disable no-param-reassign, max-len */\n\n// Validates and defaults the opt... | javascript | chosen |
[
{
"from": "system",
"value": ":art: Tweak formatting, nesting, and ordering\n"
},
{
"from": "human",
"value": "\"use babel\";\n\nimport _ from \"lodash\";\n\nfunction isMappedToGrammer(grammar) {\n return (builder) => {\n console.log(builder);\n return _.includes(builder.grammars, grammar... | javascript | chosen |
[
{
"from": "system",
"value": "Make it run on heroku\n"
},
{
"from": "human",
"value": "//Handles browser request for the react app.\n\nconst express = require('express');\nconst path = require('path');\nconst app = express();\n\napp.set('port', process.env.port || 9080);\n\napp.use('/', express.... | javascript | chosen |
[
{
"from": "system",
"value": "Check whether the user entered a name\n"
},
{
"from": "human",
"value": "const express = require('express');\nconst app = express();\nconst server = require('http').createServer(app);\nconst io = require('socket.io')(server);\n\napp.use('/public', express.static(__d... | javascript | chosen |
[
{
"from": "system",
"value": "Update CLI script to copy over css, bundle\n"
},
{
"from": "human",
"value": "#!/usr/bin/env node\n\n// Copy over the index.html\nvar fs = require(\"fs\");\nvar path = require(\"path\");\nfs.createReadStream(path.join(__dirname, \"index.html\"))\n .pipe(fs.createWr... | javascript | chosen |
[
{
"from": "system",
"value": "Use fake devices for protractor test\n"
},
{
"from": "human",
"value": "exports.config = {\n allScriptsTimeout: 11000,\n\n specs: [\n 'e2e/*.js'\n ],\n\n capabilities: {\n 'browserName': 'chrome',\n 'chromeOptions': {\n 'args': ['load-extension=/Us... | javascript | chosen |
[
{
"from": "system",
"value": "Allow the SES region to be overridden from the environment\n"
},
{
"from": "human",
"value": "module.exports = {\n sesRegion: 'us-east-1',\n sesEndpoint: process.env.SES_ENDPOINT,\n kinesisRegion: process.env.KINESIS_REGION || 'ap-southeast-2',\n kinesisEndpoint... | javascript | chosen |
[
{
"from": "system",
"value": "Change places env to production\n"
},
{
"from": "human",
"value": "/** @namespace */\nvar here = window.here || {};\n\nhere.builder = {\n config: {\n shareURL: 'https://share.here.com/',\n PBAPI: \"https://places.sit.api.here.com/places/v1/\",\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Remove unused babel 5 option\n"
},
{
"from": "human",
"value": "var gulp = require('gulp');\nvar babel = require('gulp-babel');\nrequire(\"babel-polyfill\");\n\ngulp.task('default', function () {\n return gulp.src('src/superagent-jsonp.js')\n .pipe(babel({... | javascript | chosen |
[
{
"from": "system",
"value": "Add prefix to debug logs to make clearer when not colourised\n"
},
{
"from": "human",
"value": "import chalk from 'chalk';\nimport { map } from 'lodash/fp';\n\nconst logger = {\n // default log level is silent!\n level: 0,\n\n init({ level, colour }) {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Add requirement to Comment Widget for Clipboard service.\n"
},
{
"from": "human",
"value": "angular.module( 'gj.Form.MarkdownEditor', [ 'monospaced.elastic', 'gj.Form', 'gj.Api', 'gj.Permalink' ] );\n"
},
{
"from": "gpt",
"value": "angular.module( 'gj.Fo... | javascript | chosen |
[
{
"from": "system",
"value": "Annotate scenegraph group items with runtime context.\n"
},
{
"from": "human",
"value": "import {Transform} from 'vega-dataflow';\nimport {Item, GroupItem} from 'vega-scenegraph';\nimport {inherits} from 'vega-util';\n\n/**\n * Bind scenegraph items to a scenegraph ... | javascript | chosen |
[
{
"from": "system",
"value": "Add error handling so JS errors don't break streams\n\nFixes #1\n"
},
{
"from": "human",
"value": "var gulp = require('gulp'),\n browserify = require('browserify'),\n babelify = require('babelify'),\n source = require('vinyl-source-stream'),\n paths = re... | javascript | chosen |
[
{
"from": "system",
"value": "Remove unnecessary space from the dashboard items\n"
},
{
"from": "human",
"value": "import React, { PropTypes } from 'react';\n\nconst formatValue = (item, results) => {\n if (!results.hasOwnProperty(item.query)) {\n return '—';\n }\n\n return (item.formatVal... | javascript | chosen |
[
{
"from": "system",
"value": "Make use of size instead of count()\n"
},
{
"from": "human",
"value": "import React, { Component, PropTypes } from 'react';\nimport { List } from 'immutable';\nimport { DraggableCard } from 'containers';\n\nexport default class Hand extends Component {\n static pro... | javascript | chosen |
[
{
"from": "system",
"value": "Build Monitor should now correctly respond to Jenkins being restarted\n"
},
{
"from": "human",
"value": "'use strict';\n\nangular.\n module('buildMonitor.controllers', [ 'buildMonitor.services', 'uiSlider']).\n\n controller('JobViews', function($scope, $dialog... | javascript | chosen |
[
{
"from": "system",
"value": "Make use of standard API addToStatusArea\n"
},
{
"from": "human",
"value": "/* -*- mode: js2; js2-basic-offset: 4; indent-tabs-mode: nil -*- */\n\nconst Main = imports.ui.main;\nconst Panel = imports.ui.panel;\nconst PopupMenu = imports.ui.popupMenu;\nconst Indicato... | javascript | chosen |
[
{
"from": "system",
"value": "Use factory technique for rendering component\n"
},
{
"from": "human",
"value": "var div = React.DOM.div\nvar h1 = React.DOM.h1\n\nvar MyTitle = React.createClass({\n render () {\n return (\n div(null,\n h1(null, 'Check out my first class component!'... | javascript | chosen |
[
{
"from": "system",
"value": "Add print button to resume\n"
},
{
"from": "human",
"value": "(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m... | javascript | chosen |
[
{
"from": "system",
"value": "Add rendered callback for lolliclock\n"
},
{
"from": "human",
"value": "// Time input\n\nimport { Template } from 'meteor/templating';\nimport { ReactiveForms } from 'meteor/templates:forms';\nimport { checkNpmVersions } from 'meteor/tmeasday:check-npm-versions';\n\... | javascript | chosen |
[
{
"from": "system",
"value": "Add webapp dependency to test-in-browser\n\nThis ensures the app created for test-packages will have the default\nCordova plugins installed.\n"
},
{
"from": "human",
"value": "Package.describe({\n summary: \"Run tests interactively in the browser\",\n version: '1.... | javascript | chosen |
[
{
"from": "system",
"value": "Use promises in Gulp example\n\nGulp supports returning promises to make the task not parallel, so just return it, and use promise-like functions for error logging.\r\nAlso, fix a couple typos."
},
{
"from": "human",
"value": "var NwBuilder = require('node-webkit-bu... | javascript | chosen |
[
{
"from": "system",
"value": "Increase Karma's browserNoActivityTimeout to fight timeouts in CI\n"
},
{
"from": "human",
"value": "// Karma configuration file, see link for more information\n// https://karma-runner.github.io/0.13/config/configuration-file.html\n\nmodule.exports = function (confi... | javascript | chosen |
[
{
"from": "system",
"value": "Remove old log utility function\n"
},
{
"from": "human",
"value": "import shortcut from './shortcut';\nimport setUserRequire from './require';\nimport log from './log';\n\nmodule.exports = {\n setUserRequire,\n shortcut,\n log\n}"
},
{
"from": "gpt",
... | javascript | chosen |
[
{
"from": "system",
"value": "Remove unneeded fix to cast setting to array.\n"
},
{
"from": "human",
"value": "/**\n * Module dependencies.\n */\nvar pkginfo = require('pkginfo')\n , path = require('path');\n\n\n/**\n * Creates an entity object.\n *\n * An entity is an object with properties us... | javascript | chosen |
[
{
"from": "system",
"value": ":new: Set process title to ucompiler\n"
},
{
"from": "human",
"value": "#!/usr/bin/env node\n'use strict'\n\nrequire('debug').enable('UCompiler:*')\nconst UCompiler = require('..')\nconst knownCommands = ['go', 'watch']\nconst parameters = process.argv.slice(2)\n\ni... | javascript | chosen |
[
{
"from": "system",
"value": "Fix native prototype pollution in library mode\nSince `processor` has the package `colors` as an upstream dependency, String` s prototype would get unexpectedly modified.\nThis commit fixes that issue by only loading `processor` if really needed.\n"
},
{
"from": "human"... | javascript | chosen |
[
{
"from": "system",
"value": "Enable CoreOS Install to Disk\n"
},
{
"from": "human",
"value": "// Copyright 2015, EMC, Inc.\n\nmodule.exports = {\n friendlyName: 'Install CoreOS',\n injectableName: 'Task.Os.Install.CoreOS',\n implementsTask: 'Task.Base.Os.Install',\n options: {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Add illustration to landing page\n"
},
{
"from": "human",
"value": "import React from \"react\";\nimport classes from \"./LandingPage.module.css\";\nimport LoginButtonSet from \"../../components/UI/LoginButtonSet/LoginButtonSet\";\n\nconst LandingPage = (props) => {... | javascript | chosen |
[
{
"from": "system",
"value": "Refactor to avoid dynamic module resolution\n"
},
{
"from": "human",
"value": "'use strict';\n\n/**\n* Typed array constructor which returns a typed array representing an array of 32-bit unsigned integers in the platform byte order.\n*\n* @module @stdlib/array/uint3... | javascript | chosen |
[
{
"from": "system",
"value": "Add comment explaining the WCL API proxy\n"
},
{
"from": "human",
"value": "import makeUrl from './makeUrl';\n\nconst API_BASE = process.env.REACT_APP_API_BASE || '';\nconst WCL_API_KEY = process.env.REACT_APP_WCL_API_KEY;\n\nexport default function makeWclUrl(base,... | javascript | chosen |
[
{
"from": "system",
"value": "[Backend] Exit 1 when error detected on main instruction\n\n"
},
{
"from": "human",
"value": "/*\n * Author: Alexandre Havrileck (Oxyno-zeta)\n * Date: 03/07/16\n * Licence: See Readme\n */\n\n/* ************************************* */\n/* ******** REQUIRE ... | javascript | chosen |
[
{
"from": "system",
"value": "Make it so you have to explicitly initialize the mixin\n\nAlso lets you add the mixin to other classes\n"
},
{
"from": "human",
"value": "//\n// Add boundary-handling to a Leaflet map\n//\n// The boundary layer allows exactly one boundary at a time and fires events\... | javascript | chosen |
[
{
"from": "system",
"value": "Migrate to new plugin api\n"
},
{
"from": "human",
"value": "module.exports = function ({Transformer}) {\n return new Transformer('minification.removeReactPropTypes', {\n Property: {\n exit(node) {\n if (node.computed || node.key.name !== 'propTypes'... | javascript | chosen |
[
{
"from": "system",
"value": "Fix issue with Javascript compilation\n"
},
{
"from": "human",
"value": "const get = require('lodash.get');\nconst forEach = require('lodash.foreach');\nconst defaultsDeep = require('lodash.defaultsdeep');\nconst loaderUtils = require('loader-utils');\nconst parse =... | javascript | chosen |
[
{
"from": "system",
"value": "Add cfg-response shim for local testing of CustomResources\n"
},
{
"from": "human",
"value": "var _ = require('underscore');\n\nmodule.exports.toBoolean = function(value) {\n var bValue = value;\n if (_.isString(bValue)) {\n switch (bValue.toLowerCase().trim())... | javascript | chosen |
[
{
"from": "system",
"value": "Fix task name to start BrowserSync session\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar gulp = require('gulp');\nvar watch = require('gulp-watch');\nvar gulpSequence = require('gulp-sequence');\n\n// var config = require('../config/index');\nvar templates... | javascript | chosen |
[
{
"from": "system",
"value": "Put bounds on session count for fake data generator\n"
},
{
"from": "human",
"value": "var chance = require('./fake-extension.js'),\n glimpse = require('glimpse'),\n names = [];\n\nfunction generateNames() {\n var range = chance.integerRange(3, 8);\n for... | javascript | chosen |
[
{
"from": "system",
"value": "Add button to return to dashboard from account page.\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport { compose } from 'recompose';\n\nimport PasswordChangeForm from '../PasswordChange';\nimport {\n AuthUserContext,\n withAuthorization,\n wit... | javascript | chosen |
[
{
"from": "system",
"value": "[WebBundle] Change $.fn.datepicker format to yyyy-mm-dd.\n\nThe motivation here is to allow the datetime comparison operators in the\ndatabase layer to was done so that native database comparisons can do\ntheir job.\n"
},
{
"from": "human",
"value": "/*\n * This fil... | javascript | chosen |
[
{
"from": "system",
"value": "Remove pip attribute when video ends.\n"
},
{
"from": "human",
"value": "if (!document.pictureInPictureEnabled) {\n chrome.browserAction.setTitle({ title: 'Picture-in-Picture NOT supported' });\n} else {\n chrome.browserAction.onClicked.addListener(tab => {\n c... | javascript | chosen |
[
{
"from": "system",
"value": "Add in more menu goodies\n"
},
{
"from": "human",
"value": "import Component from '../components/component.react';\nimport React from 'react-native';\nimport {logout} from '../auth/actions';\nimport {\n ScrollView,\n Text\n} from 'react-native';\n\nimport styles f... | javascript | chosen |
[
{
"from": "system",
"value": "Add check if cont-logs output is ctrl sequence and skip\n"
},
{
"from": "human",
"value": "/**\n * @module lib/container-logs\n * @exports {Class} ContainerLogs\n */\n'use strict'\n\nvar socket = require('./socket')\n\nclass ContainerLogs {\n /**\n * @param {Stri... | javascript | chosen |
[
{
"from": "system",
"value": "Add CORS in header xml request\n"
},
{
"from": "human",
"value": "document.addEventListener(\"DOMContentLoaded\", function (event) {\n // redirect to 7777 port\n // ping golang counter\n httpGetAsync(\"http://www.aracki.me:7777\", function (res) {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Use query string to influence to evaporation time\n\nthe evaporation time can be set with the '?evaporate=200000' query string\n"
},
{
"from": "human",
"value": "(function($, Fleeting){\n $(function(){\n var view = new Fleeting.CharactersView({ \n ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix an error rendering emojis\n\nSome leftovers from the default props updates\n\n[Fixes: #137486597](https://www.pivotaltracker.com/story/show/137486597)\n"
},
{
"from": "human",
"value": "import React, { PropTypes } from 'react'\nimport classNames from 'classnames... | javascript | chosen |
[
{
"from": "system",
"value": "Use const instead of let\n"
},
{
"from": "human",
"value": "/**\n * console.(log|info|error|warn) wrapper\n * @param {string} type - Console log type (\"log\"|\"info\"|\"error\"|\"warn\")\n * @param {any} data - Prints to stdout (if specify \"error\" or \"warn\" at ... | javascript | chosen |
[
{
"from": "system",
"value": "Refactor 'Remove From Itinerary' action\n"
},
{
"from": "human",
"value": "const REMOVE_FROM_ITINERARY = 'REMOVE_FROM_ITINERARY';\n\nconst removeFromItinerary = payload => (\n {\n type: REMOVE_FROM_ITINERARY,\n payload,\n }\n);\n\nexport default removeFromIt... | javascript | chosen |
[
{
"from": "system",
"value": "Add defaultoptions and event listener\n"
},
{
"from": "human",
"value": "/**\n * nanoAudioPlayer plugin for jQuery\n * by Lasse Nielsen\n * @version 0.1 \n * 03.02.2013\n * http://github.com/nano-entertainment/NanoAudioPlayer\n */\n(function($){\n $.fn.nanoAudioPla... | javascript | chosen |
[
{
"from": "system",
"value": "Debug level no longer uses console.error\n"
},
{
"from": "human",
"value": "/**\n * Return a default logger which writes to stdout and stderr.\n *\n * @return {Function} [enhanced log fn]\n * @api private\n */\nmodule.exports = function LowLevelLogger ( ) {\n\n\tvar... | javascript | chosen |
[
{
"from": "system",
"value": "Split out mock test, removed failing test. Verified Travis is working.\n"
},
{
"from": "human",
"value": "import chai, { expect } from 'chai';\nimport sinon from 'sinon';\nimport sinonChai from 'sinon-chai';\nimport System from 'systemjs';\nimport '../config.js';\n\... | javascript | chosen |
[
{
"from": "system",
"value": "Update jest diagnostics to warn only\n"
},
{
"from": "human",
"value": "module.exports = {\n transform: {\n \".ts\": \"ts-jest\"\n },\n testEnvironment: \"node\",\n testPathIgnorePatterns: [\n \"/dist/\", \n \"/node_modules/\"\n ]... | javascript | chosen |
[
{
"from": "system",
"value": "Update to comply with last release of jsgraph"
},
{
"from": "human",
"value": "'use strict';\n\nvar wavelengthToColor = require('./wavelengthToColor');\n\n\nfunction getAnnotation(pixel, color, height) {\n return {\n \"pos2\": {\n \"y\": height+... | javascript | chosen |
[
{
"from": "system",
"value": "Refactor oembed manual include for clarity\n"
},
{
"from": "human",
"value": "\"use strict\";\n\nvar readFile = require(\"fs-readfile-promise\");\nvar components = require(\"server-components\");\nvar domino = require(\"domino\");\nvar moment = require(\"moment\");\... | javascript | chosen |
[
{
"from": "system",
"value": "Enable jsx to be loaded from js tests in jest\n"
},
{
"from": "human",
"value": "// jest.config.js\nmodule.exports = {\n verbose: true,\n globals: {\n __testing__: true\n },\n roots: ['app/javascript'],\n setupFiles: ['./config/jest.setup.js'],\n testRegex:... | javascript | chosen |
[
{
"from": "system",
"value": "Make sure initCustomEvent is called properly"
},
{
"from": "human",
"value": "/* global chrome */\n\n(function () {\n document.addEventListener('window.remoteDebug.getDebugSocket', function (e) {\n chrome.runtime.sendMessage({\n cmd: 'getDebugSocket'\n }... | javascript | chosen |
[
{
"from": "system",
"value": "Fix build with new sass-loader\n"
},
{
"from": "human",
"value": "const MiniCssExtractPlugin = require('mini-css-extract-plugin');\n\nmodule.exports = {\n test: /\\.s?css$/i,\n use: [\n MiniCssExtractPlugin.loader,\n {\n loader: 'css-loader',\n opt... | javascript | chosen |
[
{
"from": "system",
"value": "Fix chromecast API not initializing\n"
},
{
"from": "human",
"value": "import _ from 'lodash';\nimport { remote } from 'electron';\n\nimport '../generic';\n\n// Initialize the global Logger to forward to the main process.\nwindow.Logger = remote.getGlobal('Logger');... | javascript | chosen |
[
{
"from": "system",
"value": "Add inline SVG feature detection\n"
},
{
"from": "human",
"value": "(function() {\n\n // Feature detection results\n const supports = {};\n\n // Detect localStorage support\n try {\n localStorage.setItem('test', 'test');\n localStorage.removeItem('test');\... | javascript | chosen |
[
{
"from": "system",
"value": "Remove mention of Parcel v1 issue ever being resolved in v1\n"
},
{
"from": "human",
"value": "/**\n * PDF.js Worker entry file.\n *\n * This file is identical to Mozilla's pdf.worker.entry.js, with one exception being placed inside\n * this bundle, not theirs. This... | javascript | chosen |
[
{
"from": "system",
"value": "Stop browser-sync from opening a browser automatically\n"
},
{
"from": "human",
"value": "var dest = \"./build/\";\nvar src = './app/';\n\nmodule.exports = {\n\tbrowserSync: {\n\t\tserver: {\n\t\t\tbaseDir: dest\n\t\t},\n\t\tfiles: [\n\t\t\tdest + \"**\",\n\t\t\t// ... | javascript | chosen |
[
{
"from": "system",
"value": "Add support for prototype mocking\n"
},
{
"from": "human",
"value": "var assert = require('chai').assert;\nvar deepEqual = require('deep-equal');\nvar makeMockFunction = require('./makeMockFunction');\n\nmodule.exports = function makeMock(object, type) {\n\n var ar... | javascript | chosen |
[
{
"from": "system",
"value": "Allow one event-stream error before logging\n"
},
{
"from": "human",
"value": "var EventSource = require(\"eventsource\"),\n EventEmitter = require(\"events\").EventEmitter,\n utils = require(\"radiodan-client\").utils,\n http = requ... | javascript | chosen |
[
{
"from": "system",
"value": "Include reference to possible glyphicons\n"
},
{
"from": "human",
"value": "import React from \"react\";\n\n\nexport default React.createClass({\n displayName: \"Glyphicon\",\n\n render: function() {\n return (\n <i className={\"glyphicon glyphic... | javascript | chosen |
[
{
"from": "system",
"value": "Fix git clone failed because recursive argument error\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar pathFn = require('path');\nvar chalk = require('chalk');\nvar fs = require('hexo-fs');\nvar tildify = require('tildify');\nvar spawn = require('hexo-util').... | javascript | chosen |
[
{
"from": "system",
"value": "[TASK] Read database url from config not environment.\n"
},
{
"from": "human",
"value": "Sequelize = require('sequelize')\npg = require('pg').native;\n\nvar databaseUrl = process.env.DATABASE_URL;\n\nif (databaseUrl) {\n var match = databaseUrl.match(/postgres:\\/\... | javascript | chosen |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.