conversations listlengths 2 3 | source stringclasses 1
value | stack stringclasses 1
value |
|---|---|---|
[
{
"from": "system",
"value": "Add link to color picker original project\n"
},
{
"from": "human",
"value": "const ColorPicker = require(\"./components/ColorPicker\");\n\n\nmodule.exports = ColorPicker;\n"
},
{
"from": "gpt",
"value": "const ColorPicker = require(\"./components/ColorPi... | javascript | chosen |
[
{
"from": "system",
"value": "Update to not use newer ES6 function so we can support Node 0.12\n"
},
{
"from": "human",
"value": "// modules\nvar assert = require('assert')\nvar _ = require('underscore')\nvar fs = require('fs');\nvar S = require('string');\nvar ... | javascript | chosen |
[
{
"from": "system",
"value": "jQuery: Fix code style, remove JSHint comment.\n"
},
{
"from": "human",
"value": "/**\n * <%= name %>\n *\n * Makes bla bla.\n *\n * @version 0.0.0\n * @requires jQuery\n * @author <%= authorName %>\n * @copyright <%= (new Date).getFullYear() %> <%= authorName %>, <... | javascript | chosen |
[
{
"from": "system",
"value": "Add a sort function which is not bind on any event for now.\n"
},
{
"from": "human",
"value": "define(['backbone', 'handlebars', 'views/row', 'text!../../../src/templates/datagrid.hbs'], function(Backbone, Handlebars, Row, datagridTemplate) {\n\n var Datagrid = Bac... | javascript | chosen |
[
{
"from": "system",
"value": "Fix a bug while clicking the first button to show the lesson\n"
},
{
"from": "human",
"value": "BustinBash.Directory.View = function() {}\n\nBustinBash.Directory.View.prototype = {\n\n\thideAndShowDOM: function(data) {\n\t\t$(data.Hide).hide();\n\t\t$(data.Show).sho... | javascript | chosen |
[
{
"from": "system",
"value": "Adjust new API on controller\n"
},
{
"from": "human",
"value": "/**\n * @fileOverview Level 01 controller.\n */\n\nvar Vector = require('../vector/main.vector');\n\n/**\n * Level 01 controller.\n *\n * @constructor\n */\nvar Level01 = module.exports = function () {\... | javascript | chosen |
[
{
"from": "system",
"value": "Add failing test for 'only' object keys\n"
},
{
"from": "human",
"value": "const rules = require('./index').rules;\nconst RuleTester = require('eslint').RuleTester;\nconst ruleTester = new RuleTester();\n\nruleTester.run('no-only-tests', rules['no-only-tests'], {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix missing server error information\n"
},
{
"from": "human",
"value": "'use strict';\n\n\nconst http = require('http');\n\nconst { host, port } = require('../../../config');\nconst { addStopFunctions } = require('./stop');\n\n\n// Start HTTP server\nconst startServ... | javascript | chosen |
[
{
"from": "system",
"value": "Exit phantomJS after every screenshot to kill phantom process\n"
},
{
"from": "human",
"value": "var http = require('http');\nvar phantom=require('node-phantom-simple');\n\nhttp.createServer(function (req, res) {\n phantom.create(function(err,ph) {\n return ph.c... | javascript | chosen |
[
{
"from": "system",
"value": "Clean up code and add timestamp\n"
},
{
"from": "human",
"value": "const fs = require('fs')\nconst Twit = require('twit')\nconst config = require('./config')\n\nconst quotes = JSON.parse(fs.readFileSync('./data/backup-2016-11-03.json', 'utf8'))\nconst T = new Twit(c... | javascript | chosen |
[
{
"from": "system",
"value": "Add help text for the tweet command\n"
},
{
"from": "human",
"value": "var util = require('util')\n , twitter = require('twitter')\n , Stream = require('stream')\n , repl = require('repl')\n , keys = require('./keys')\n , local = repl.start()\n , first = true\... | javascript | chosen |
[
{
"from": "system",
"value": "Rebuild pages if their layout changes\n"
},
{
"from": "human",
"value": "const chokidar = require('chokidar')\nconst compile = require('./compiler').run\n\nmodule.exports = function () {\n const watcher = chokidar.watch(process.cwd(), {\n ignored: /dist|layouts|... | javascript | chosen |
[
{
"from": "system",
"value": "Fix rendering of x-Axis labels\n"
},
{
"from": "human",
"value": "export default function({\n renderedXAxis,\n renderedYAxis,\n xLabel,\n yLabel,\n width\n}) {\n let _y = this.axis == 'y'\n let axis = _y ? renderedYAxis : renderedXAxis\n\n if (axis) {\n l... | javascript | chosen |
[
{
"from": "system",
"value": "[fix] Remove err, value in favor of this.value\n"
},
{
"from": "human",
"value": "var five = require(\"../lib/johnny-five.js\"),\n board, photoresistor;\n\nboard = new five.Board();\n\nboard.on(\"ready\", function() {\n\n // Create a new `photoresistor` hardware... | javascript | chosen |
[
{
"from": "system",
"value": "Add handling to InvalidChannelNameError for generating reply messages for several other commands\n"
},
{
"from": "human",
"value": "\nvar\n\textend = req('/lib/utilities/extend'),\n\tBaseError = req('/lib/errors/base'),\n\tErrorCodes = req('/lib/consta... | javascript | chosen |
[
{
"from": "system",
"value": "Fix issue with sharing states between different parsings\n"
},
{
"from": "human",
"value": "const nearley = require('nearley');\nconst grammar = require('./grammar/grammar');\nconst parser = new nearley.Parser(nearley.Grammar.fromCompiled(grammar));\n\nmodule.export... | javascript | chosen |
[
{
"from": "system",
"value": "Trim error were thrown when linked ember-cli had deatched HEAD.\n\nIf the contents of the ./git/HEAD file does not return a ref path,\nit's a SHA value so that is what will be used.\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar fs = require('fs');\nvar p... | javascript | chosen |
[
{
"from": "system",
"value": "Clean up js for index.html a bit\n"
},
{
"from": "human",
"value": ";(function($) {\n\n // initalize Editable\n Editable.init({\n log: false\n });\n\n\n $(document).ready(function() {\n var tooltip = $('<div class=\"selection-tip\" style=\"display:none;\">... | javascript | chosen |
[
{
"from": "system",
"value": "(config): Remove preact for now. Problems with event bubbling.\n"
},
{
"from": "human",
"value": "var path = require('path');\nvar rootPath = path.join(__dirname, '..')\n\nmodule.exports = { \n '~': path.join(rootPath, 'src', 'client'),\n '~server': path.join(... | javascript | chosen |
[
{
"from": "system",
"value": "Change caseing to conform with shp header\n"
},
{
"from": "human",
"value": "'use strict'\n\nmodule.exports = function readBoundingBox (buffer, offset) {\n const Xmin = buffer.readDoubleLE(offset, true)\n const Ymin = buffer.readDoubleLE(offset + 8, true)\n const... | javascript | chosen |
[
{
"from": "system",
"value": "Clear textarea in cloned row\n"
},
{
"from": "human",
"value": "/* jslint browser: true */\n/* global $ */\n(function(){\n var makeCloneable = function(selector) {\n var scope = $(selector);\n\n var update_remove_one_visibility = function() {\n var hidde... | javascript | chosen |
[
{
"from": "system",
"value": "Move running flag to before htrtime start\n"
},
{
"from": "human",
"value": "'use strict';\n\nexport class Timer {\n\tconstructor() {\n\t\tthis.reset();\n\t}\n\n\t/**\n\t * Start the timer\n\t*/\n\tstart() {\n\t\tif(this._ran) throw new Error('timer already ran. use... | javascript | chosen |
[
{
"from": "system",
"value": "ember/config: Store config in JS file\n"
},
{
"from": "human",
"value": "/*jshint node:true*/\n/* global require, module */\nvar EmberApp = require('ember-cli/lib/broccoli/ember-app');\n\nmodule.exports = function(defaults) {\n var app = new EmberApp(defaults, {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Create page will redirect to full page if already created\n"
},
{
"from": "human",
"value": "angular.module('createPageController.controller', [])\n .controller('createPageController', function($scope, $http, $routeParams, $location, pageService) {\n $scope.mess... | javascript | chosen |
[
{
"from": "system",
"value": "Check RSS feed on startup\n"
},
{
"from": "human",
"value": "$(function(){\n\n\treadFileIntoBuffer(batotoJSONFile, function(buffer){\n\n\t\tif (buffer){\n\t\t\tbatotoJSON = JSON.parse(buffer);\n\t\t\tif ('chapters' in batotoJSON){\n\t\t\t\t$.each(batotoJSON.chapters... | javascript | chosen |
[
{
"from": "system",
"value": "Switch from fetch to beacon\n"
},
{
"from": "human",
"value": "document\r\n .querySelectorAll('pre')\r\n .forEach(node => {\r\n node.title = 'Copy to clipboard';\r\n node.classList.add('copy');\r\n node.onclick = function (event) {\r\n navigator.clip... | javascript | chosen |
[
{
"from": "human",
"value": "Write some of the code for loading blog posts\n"
},
{
"from": "gpt",
"value": "// TODO: don't just assume this is the homepage, account for the fact that the user might be visiting #blog/something\n// And don't forget to window.addEventListener('hashchange', () => {}... | javascript | chosen |
[
{
"from": "system",
"value": "Add action to ignore original stylesheets\n"
},
{
"from": "human",
"value": "\nimport AppDispatcher from '../dispatchers/dispatcher';\nimport AppConstants from '../constants/constants';\n\nexport default {\n\tswitchView: viewType => {\n\t\tAppDispatcher.dispatch({\n... | javascript | chosen |
[
{
"from": "system",
"value": "Enable rules that already pass\n\nThese rules pass with our current codebase and require no changes.\n"
},
{
"from": "human",
"value": "/* eslint-env node */\n'use strict';\n\nvar defaultAllowedBaseStrings = ['(', ')', ',', '.', '&', '+', '-', '=', '*', '/', '#', '%... | javascript | chosen |
[
{
"from": "system",
"value": "Add empty slate for cases where daily prices is not allowed\n"
},
{
"from": "human",
"value": "import React, { PureComponent, PropTypes } from 'react';\nimport DailyPricesTable from './DailyPricesTable';\n\nexport default class DailyPricesCard extends PureComponent ... | javascript | chosen |
[
{
"from": "system",
"value": "Remove now useless cache deletion\n"
},
{
"from": "human",
"value": "'use strict';\n\nconst dateFormat = require('dateformat');\nconst { defineSupportCode } = require('cucumber');\n\ndefineSupportCode(function ({ Before, After }) {\n\n Before(function () {\n bro... | javascript | chosen |
[
{
"from": "system",
"value": "Expand min and max sizes for tempvar dropdowns\n"
},
{
"from": "human",
"value": "import _ from 'lodash'\nimport calculateSize from 'calculate-size'\n\nexport const minDropdownWidth = 146\nexport const maxDropdownWidth = 300\nexport const dropdownPadding = 30\n\ncon... | javascript | chosen |
[
{
"from": "system",
"value": "Use fetch instead of axios as http client"
},
{
"from": "human",
"value": "import axios from 'Axios'\n\nexport default {\n getSeries () {\n return axios.get('http://api.tvmaze.com/search/shows?q=bad')\n }\n}"
},
{
"from": "gpt",
"value": "ex... | javascript | chosen |
[
{
"from": "system",
"value": "Extend the static demo data with customOptions\n"
},
{
"from": "human",
"value": "const options = [\n { label: 'Chocolate', value: 'chocolate' },\n { label: 'Vanilla', value: 'vanilla' },\n { label: 'Strawberry', value: 'strawberry' },\n { label: 'Caramel', valu... | javascript | chosen |
[
{
"from": "system",
"value": "Print foods in a vertical stack\n"
},
{
"from": "human",
"value": "'use strict';\n\nfunction makeString(foods) {\n return foods.toString();\n}\n\nfunction update () {\n var labelSprite = _.find(this.sprite.children, function(child) {\n return child instanceof P... | javascript | chosen |
[
{
"from": "system",
"value": "Change treatment of space character in URLs\n\njQuery changed it from using '+' to '%20' between\nversions 1 and 3. This updates the test to match.\n"
},
{
"from": "human",
"value": "// general helpers, not related to the DOM and usable in different contexts\n\n// t... | javascript | chosen |
[
{
"from": "system",
"value": "Test jetzt erfolgreich: karyo und links sind definiert\n"
},
{
"from": "human",
"value": "var karyo;\nvar links;\n\ndescribe(\"link_to_coords\", function(){\n\t\n\tbeforeEach(function(done){\n\t\tloadKaryoFile(karyoFile, function(data){\n\t\t\tkaryo_to_coords(data);... | javascript | chosen |
[
{
"from": "system",
"value": "Test explicitly specifying an arity in curry\n"
},
{
"from": "human",
"value": "(function() {\n module(\"R.curry\");\n\n var curry = require('eigensheep/curry')['default'];\n var adder = function(a, b, c, d) {\n return a + b + c + d;\n };\n var curriedAdder ... | javascript | chosen |
[
{
"from": "system",
"value": "Move doc history to proper place.\n"
},
{
"from": "human",
"value": "// Single certificate submitted view\n\n'use strict';\n\nvar db = require('mano').db\n , endsWith = require('es5-ext/string/#/ends-with')\n , documentView ... | javascript | chosen |
[
{
"from": "system",
"value": "Use operationCreator instead of operationType in ConnectedOperationContainer\n"
},
{
"from": "human",
"value": "import { connect } from 'react-redux';\nimport { bindActionCreators } from 'redux';\nimport PropTypes from 'prop-types';\n\nimport OperationContainer from... | javascript | chosen |
[
{
"from": "system",
"value": "Update midi player javascript file\n"
},
{
"from": "human",
"value": "var $ = require(\"jquery\");\n\n\n// Initialize player and register event handler\nvar Player = new MidiPlayer.Player();\n\nvar playTrack = function (filename, pk) {\n // Load a MIDI file\n MIDI... | javascript | chosen |
[
{
"from": "system",
"value": "Fix for downstream require-directory issues, make paths system-independent"
},
{
"from": "human",
"value": "/*\n * grunt-load-options\n * https://github.com/chriszarate/grunt-load-options\n *\n * Copyright (c) 2013-2014 Chris Zarate\n * Licensed under the MIT licens... | javascript | chosen |
[
{
"from": "system",
"value": "Make sure the device is detected as catgory\n"
},
{
"from": "human",
"value": "module.exports = function (RED) {\n\tfunction LgtvRequestNode(n) {\n\t\tRED.nodes.createNode(this, n);\n\t\tvar node = this;\n\t\tthis.tv = n.tv;\n\n\t\tthis.tvConn = RED.nodes.getNode(th... | javascript | chosen |
[
{
"from": "system",
"value": "Add `lodash.memoize` to benchmark suite\n"
},
{
"from": "human",
"value": "'use strict'\n\nlet Benchmark = require('benchmark')\nlet memoize1 = require('./1')\nlet underscore = require('underscore').memoize\n\n//\n// Fibonacci suite\n//\n\nlet fibonacci = (n) => {\n... | javascript | chosen |
[
{
"from": "system",
"value": "Fix indentation of the C grammar\n"
},
{
"from": "human",
"value": "define(function() {\n\n // Export\n return function(Prism) {\n\n Prism.languages.c = Prism.languages.extend('clike', {\n \t'keyword': /\\b(asm|typeof|inline|auto|break|case|char|const|contin... | javascript | chosen |
[
{
"from": "system",
"value": "Fix response handling when Content-Type header not present\n"
},
{
"from": "human",
"value": "export default class HttpApi {\n constructor (prefix = '') {\n this.prefix = prefix\n this.opts = {\n credentials: 'same-origin',\n headers: new Headers({\... | javascript | chosen |
[
{
"from": "system",
"value": "Set the radio to the previous status if there is a fail\n"
},
{
"from": "human",
"value": "FrontendCore.define('on-off-table', ['devicePackage' ], function () {\r\n return {\r\n onStart: function () {\r\n\r\n FrontendCore.requireAndStart('notifi... | javascript | chosen |
[
{
"from": "system",
"value": "Kill this use strict for now\n\nShould explicitly assign to global at some point I guess.\n"
},
{
"from": "human",
"value": "/*global browser:true, protractor:true, httpBackend:true, By:true, expect:true, Promise:true */\r\n'use strict';\r\n\r\nvar CustomWorld = (fu... | javascript | chosen |
[
{
"from": "system",
"value": "Check for eval match and exit right away. Fix not returning error messages.\n"
},
{
"from": "human",
"value": "var format = require(\"util\").format;\n\nvar TennuEval = {\n requires: [\"admin\"],\n init: function(client, imports) {\n\n function handleEv... | javascript | chosen |
[
{
"from": "system",
"value": "Fix how `HTMLElement.prototype` is set.\n"
},
{
"from": "human",
"value": "/**\n * @license\n * Copyright (c) 2016 The Polymer Project Authors. All rights reserved.\n * This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.... | javascript | chosen |
[
{
"from": "system",
"value": "Adjust url from custom baselayer in OSM\n"
},
{
"from": "human",
"value": "PluginsAPI.Map.addActionButton(function(options){\n\tif (options.tiles.length > 0){\n\t\t// TODO: pick the topmost layer instead\n\t\t// of the first on the list, to support\n\t\t// maps that... | javascript | chosen |
[
{
"from": "system",
"value": "Change to send one message.\n"
},
{
"from": "human",
"value": "'use strict';\n\nconst Promise = require('promise');\nconst azure = require('azure-sb'); \nconst asyncEachLimit = require('async/eachLimit');\nconst trackDependency = require('../appinsights/AppInsightsC... | javascript | chosen |
[
{
"from": "system",
"value": "Fix PersonaBar loading when within an iframe\n"
},
{
"from": "human",
"value": "'use strict';\ndefine(['jquery'], function ($) {\n return {\n init: function () {\n var inIframe = window !== window.top && typeof window.top.dnn !== \"undefined\";\... | javascript | chosen |
[
{
"from": "system",
"value": "Remove a check that is probably useless\n"
},
{
"from": "human",
"value": "var replaceAll = function( oldToken ) {\n var configs = this;\n return {\n from: function( string ) {\n return {\n to: function( newToken ) {\n var _token;\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix falling out of the ember run loop in run.after method\n"
},
{
"from": "human",
"value": "/**\n @module ember-flexberry\n*/\n\nimport Ember from 'ember';\n\n/**\n Injects 'after' method into 'Ember.run' namespace.\n\n @for ApplicationInitializer\n @method emb... | javascript | chosen |
[
{
"from": "system",
"value": "Resolve commit about local time\n"
},
{
"from": "human",
"value": "/**\n * Parse task and return task info if\n * the task is valid, otherwise throw\n * error.\n * @param {string} query Enetered task\n * @return {object} Task info containing\n * ... | javascript | chosen |
[
{
"from": "system",
"value": "Format volume and snapshot size quota using filesize filter [WAL-813].\n"
},
{
"from": "human",
"value": "// @ngInject\nexport function quotaName($filter) {\n var names = {\n floating_ip_count: gettext('Floating IP count'),\n vcpu: gettext('vCPU count'),\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Revert code that broke changing language.\n"
},
{
"from": "human",
"value": "// We save the user language preference in the user profile, and use that to set\n// the language reactively. If the user is not connected we use the language\n// information provided by th... | javascript | chosen |
[
{
"from": "system",
"value": "Use req.query instead of req.param\n"
},
{
"from": "human",
"value": "var api = require(\"./api\");\n\nmodule.exports = function(app) {\n\n // View endpoints\n app.get(\"/\", function(req, res) {\n res.sendFile(__dirname + \"/views/index.html\");\n }... | javascript | chosen |
[
{
"from": "system",
"value": "Access proptypes via prop-types packages instead of React in LimitSelect component\n"
},
{
"from": "human",
"value": "/**\n *\n * LimitSelect\n *\n */\n\nimport React from 'react';\n// import PropTypes from 'prop-types';\nimport { FormattedMessage } from 'react-intl... | javascript | chosen |
[
{
"from": "system",
"value": "Debug pour recherche d'un bug\n"
},
{
"from": "human",
"value": "'use strict';\n\nconst core = require('./core.js');\nconst fd = require('./field.js');\nconst service = require('./../services/services.js');\n\n/*\n* Fonction qui traite les réponses de type bonjour... | javascript | chosen |
[
{
"from": "system",
"value": "Fix enter keydown events in picker views\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar BaseView = require('../base-view');\n\nfunction BasePickerView() {\n BaseView.apply(this, arguments);\n\n this._initialize();\n}\n\nBasePickerView.prototype = Object.c... | javascript | chosen |
[
{
"from": "system",
"value": "Replace quotes and ensure errors are handled\n"
},
{
"from": "human",
"value": "var dgram = require('dgram'),\n LogPacket = require('./logpacket.js');\n\nvar server = dgram.createSocket('udp4');\n\nvar secret = \"\";\n\nfunction getAddress(address) {\n\treturn ad... | javascript | chosen |
[
{
"from": "system",
"value": "Fix issues found by jshint\n"
},
{
"from": "human",
"value": "var express = require('express');\nvar http = require('http');\nvar url = require('url');\nvar restify = require('express-restify-mongoose');\nvar mongoose = require('mongoose');\n\nvar Artist = require('... | javascript | chosen |
[
{
"from": "system",
"value": "Remove ability to pass port as arg\n\nCucumber adds arguments to server start command which caused the port to\nbe assigned to NaN and it would break the server.\n"
},
{
"from": "human",
"value": "// DEPENDENCIES\nvar express = require('express');\nvar app = express... | javascript | chosen |
[
{
"from": "system",
"value": "Move promisified functions out of the actual function that uses them.\n"
},
{
"from": "human",
"value": "import fs from 'fs';\nimport path from 'path';\nimport promisify from 'es6-promisify';\nimport {\n InvalidFile,\n InvalidJsonString\n} from './errors';\n\nexpo... | javascript | chosen |
[
{
"from": "system",
"value": "Update the benchmark to use the document.readyState to measure page-completedness\nrather than the onload event. Extensions were moved from the pre-onload state\nto running at document idle some time ago.\n\nBUG=none\nTEST=none\n\nReview URL: http://codereview.chromium.org/397... | javascript | chosen |
[
{
"from": "system",
"value": "Call remote 'fetch_info' on feed, return promise\n"
},
{
"from": "human",
"value": "import Ember from 'ember';\n\nexport default Ember.Service.extend({\n store: Ember.inject.service(),\n feedModel: null,\n createOrFindFeedModel: function() {\n if (this.get('fe... | javascript | chosen |
[
{
"from": "system",
"value": "Test with this \"util\" lib, not grunt.util.\n"
},
{
"from": "human",
"value": "module.exports = function(grunt) {\n\n grunt.registerTask('default', function(text) {\n var done = this.async();\n grunt.util.spawn({\n grunt: true,\n args: ['--gruntfil... | javascript | chosen |
[
{
"from": "system",
"value": "Fix test for deploying Meteor 1.2\n"
},
{
"from": "human",
"value": "var config = require('./mup.js');\n\nconfig.meteor.path = '../helloapp-old';\ndelete config.meteor.docker.image;\n\nmodule.exports = config;\n"
},
{
"from": "gpt",
"value": "var config ... | javascript | chosen |
[
{
"from": "system",
"value": "Use let instead of const"
},
{
"from": "human",
"value": "/*\n * This script will automaticly look at the closest entity.\n * It checks for a near entity every tick.\n */\nconst mineflayer = require('mineflayer')\n\nif (process.argv.length < 4 || process.argv.length... | javascript | chosen |
[
{
"from": "system",
"value": "Fix a typo in example"
},
{
"from": "human",
"value": "var mdns = require('../');\r\n\r\nvar TIMEOUT = 5000; //5 seconds\r\n\r\n\r\nvar browser = new mdns.createBrowser(); //defaults to mdns.ServiceType.wildcard\r\n//var browser = new mdns.Mdns(mdns.tcp(\"googlecast... | javascript | chosen |
[
{
"from": "system",
"value": "Fix not returning the state\n"
},
{
"from": "human",
"value": "\"use strict\";\n\nimport { Constants as AssessmentMetaConstants } from '../actions/assessment_meta';\n\nconst initialState = {};\n\nexport default (state = initialState, action) => {\n\n switch(actio... | javascript | chosen |
[
{
"from": "system",
"value": "Make test name more accurate.\n"
},
{
"from": "human",
"value": "import { moduleFor, test } from 'ember-qunit';\nimport Ember from 'ember';\n\nmoduleFor('controller:nodes.detail.files.provider.file', 'Unit | Controller | file', {\n // Specify the other units that a... | javascript | chosen |
[
{
"from": "system",
"value": "Complete the modified hierarchical track selector to remove the 'Annotations' and 'DNA' tracks\n"
},
{
"from": "human",
"value": "define([\n\t\"dojo/_base/declare\",\n\t'JBrowse/View/TrackList/Hierarchical'\n],\nfunction(declare,Hierarchical) {\n\treturn declare('We... | javascript | chosen |
[
{
"from": "system",
"value": "Move table class to postprocessing step\n\nWe don't want to do this as part of markdown rendering, because it makes\nour XSS filter more complicated. In general, we do not want to allow the\nuser to specify their own class attributes. So every class attribute\ngenerated by the ... | javascript | chosen |
[
{
"from": "system",
"value": "Use Chrome as well as Firefox for the unit tests\n"
},
{
"from": "human",
"value": "module.exports = function(config) {\n config.set({\n frameworks: [ \n 'jasmine', \n 'karma-typescript'\n ],\n plugins: [\n 'karma-typescript',\n 'karma-... | javascript | chosen |
[
{
"from": "system",
"value": "Add comment for code clarity\n"
},
{
"from": "human",
"value": "// This file makes all join table relationships\nvar Sequelize = require('sequelize');\nvar sequelize = new Sequelize('escape', 'escape', 'escapeacft', {\n dialect: 'mariadb',\n host: 'localhost'\n});... | javascript | chosen |
[
{
"from": "system",
"value": "Add test to ensure each rule is documented\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar expect = require('chai').expect,\n fs = require('fs'),\n path = require('path'),\n rulesDir = path.join(__dirname, '../lib/rules/'),\n plugin = require('..... | javascript | chosen |
[
{
"from": "system",
"value": "Use a number instead of hard coded spaces in json stringify\n"
},
{
"from": "human",
"value": "import GraphQLJSClient from '../src/graphql-client';\n\nfunction recordTypes() {\n const types = GraphQLJSClient.trackedTypes();\n\n if (typeof require === 'function') {... | javascript | chosen |
[
{
"from": "system",
"value": "Set displayName for Form class\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar React = require('react');\nvar api = require('./protocols/api');\nvar config = require('./config');\nvar getFactory = require('./factories').getFactory;\nvar getReport = require('... | javascript | chosen |
[
{
"from": "system",
"value": "Change all 1d to 24h\n"
},
{
"from": "human",
"value": "export const defaultRuleConfigs = {\n deadman: {\n period: '10m',\n },\n relative: {\n change: 'change',\n period: '1m',\n shift: '1m',\n operator: 'greater than',\n value: '90',\n },\n t... | javascript | chosen |
[
{
"from": "system",
"value": "Remove the reference to acc, now refers to prod again.\n"
},
{
"from": "human",
"value": "(function () {\n 'use strict';\n\n angular\n .module('dpShared')\n .constant('API_CONFIG', {\n ROOT: 'https://api-acc.datapunt.amsterdam.nl/',\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Add build to gulp serve task dependencies.\n"
},
{
"from": "human",
"value": "var gulp = require('gulp');\nvar $ = require('gulp-load-plugins')();\nvar config = require('../config');\n\ngulp.task('watch', ['browserify:build', 'scripts:watch', 'sass:watch', 'template... | javascript | chosen |
[
{
"from": "system",
"value": "Fix loading names.json for example 29\n"
},
{
"from": "human",
"value": "angular.module('nameApp', [])\n .factory('PersonsService', personsService)\n .directive('name', nameDirective)\n .controller('ExampleCtrl', ExampleCtrl);\n\nExampleCtrl.$inject = ['Per... | javascript | chosen |
[
{
"from": "system",
"value": "Add proptype validation to PagingButtons component\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport './paging-buttons.scss';\n\nclass PagingButtons extends React.Component {\n render() {\n const prev = this.props.prev;\n const next = this... | javascript | chosen |
[
{
"from": "system",
"value": "Document shortcuts for VLC Remote"
},
{
"from": "human",
"value": "// ==UserScript==\n// @name VLC Remote\n// @namespace fatmonkeys\n// @include http://[IP address of VLC Remote server]:8080/\n// @version 1\n// @grant none\n// ==/UserScript==\... | javascript | chosen |
[
{
"from": "system",
"value": "Add test for `removeAdditional` when using a schema to validate additional properties.\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar Ajv = require(typeof window == 'object' ? 'ajv' : '../lib/ajv')\n , should = require('chai').should()\n , stableStringify... | javascript | chosen |
[
{
"from": "system",
"value": "Switch to using function keyword instead of arrow functions\n"
},
{
"from": "human",
"value": "'use babel'\n\nSoftWrapIndicator = require('../lib/soft-wrap-indicator')\n\ndescribe('SoftWrapIndicatorPackage', () => {\n let atomEnv, indicator\n\n beforeEach(async ()... | javascript | chosen |
[
{
"from": "system",
"value": "Set the URL to include the modified query. Part of STRIPES-85.\n\nAt present we express URLs in the form:\n\thttp://localhost:3000/users/water\nwith the query in the path rather than in the URL query, as:\n\thttp://localhost:3000/users?q=water\n\nThat's just because at present ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix logic for checking google maps exists\n"
},
{
"from": "human",
"value": "\"use strict\";\n\nvar invariant = require('react/lib/invariant');\n\ninvariant(\n window.google || window.google.maps,\n '`google.maps` global object not found, make sure ' +\n 'Googl... | javascript | chosen |
[
{
"from": "system",
"value": "Remove specs for module.load function\n"
},
{
"from": "human",
"value": "\n\ndefine(function(require, exports, mod) {\n\n var test = require('../../../test')\n\n test.assert(seajs.config() === seajs, 'sea.config is chainable')\n test.assert(seajs.emit() === seajs... | javascript | chosen |
[
{
"from": "system",
"value": "fix: Write original string to the clipboard as text and new as RTF\n"
},
{
"from": "human",
"value": "'use strict'\n\nconst path = require('path')\nconst rtfRenderer = require('../lib/')\nconst execa = require('execa')\n\nmodule.exports = function codeHighlight(clip... | javascript | chosen |
[
{
"from": "system",
"value": "Fix call to on session disconnected\n"
},
{
"from": "human",
"value": "console.log(\"Create app module\");\nvar learnApp = angular.module('LearnApp', []);\n\nvar LearnController = function($scope) {\n\tvar _this = this;\n\twindow.castReceiverManager = cast.receiver... | javascript | chosen |
[
{
"from": "system",
"value": "Add error reporting to the REPL interface\n"
},
{
"from": "human",
"value": "#!/usr/bin/env node\n\nvar repl = require('repl');\nvar protocol = require('../lib/protocol.json');\nvar Chrome = require('../');\n\nChrome(function (chrome) {\n var chromeRepl = repl.st... | javascript | chosen |
[
{
"from": "system",
"value": "Make extendMake run only once\n"
},
{
"from": "human",
"value": "module.exports = function (context) {\n return {\n $: function (expression) {\n return expression\n },\n\n extend: {\n extendables: {},\n add: function (selector, cssString) {\... | javascript | chosen |
[
{
"from": "system",
"value": "Allow end-user to force `isWindowFocused` prop\n"
},
{
"from": "human",
"value": "import React, { Component } from 'react';\nimport PropTypes from 'prop-types';\nimport Close from './Close';\nimport Minimize from './Minimize';\nimport Resize from './Resize';\n\nvar ... | javascript | chosen |
[
{
"from": "system",
"value": "Send user to home when he logs out\n"
},
{
"from": "human",
"value": "import React, { Component } from 'react';\nimport * as types from '../../../constants/ActionTypes'\nimport { logout } from '../../../actions/login';\nimport { connect } from 'react-redux';\n\nclas... | javascript | chosen |
[
{
"from": "system",
"value": "Add env variable to disable this plugin\n\nThis is necessary because we have a stage hubot and a real hubot at our\ncompany and we don't want the stage hubot saying anything about the RSS\nfeeds.\n"
},
{
"from": "human",
"value": "import getFeed from './rss-feed-pol... | javascript | chosen |
[
{
"from": "system",
"value": "Include babel polyfill for github pages demo\n"
},
{
"from": "human",
"value": "/* global require, module */\nvar EmberAddon = require('ember-cli/lib/broccoli/ember-addon')\n\nmodule.exports = function (defaults) {\n var app = new EmberAddon(defaults, {\n\n babe... | javascript | chosen |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.