conversations listlengths 2 3 | source stringclasses 1
value | stack stringclasses 1
value |
|---|---|---|
[
{
"from": "system",
"value": "Change create supscription to PUT call\n"
},
{
"from": "human",
"value": "var express = require('express');\nvar path = require('path');\n\nvar home = require('./routes/home.js');\nvar api = require('./routes/api.js');\n\nvar port = process.env.PORT || 5000;\n\nvar ... | javascript | chosen |
[
{
"from": "system",
"value": "Add missing date fields to createIndicator repo\n"
},
{
"from": "human",
"value": "import gql from \"graphql-tag\";\n\nclass IndicatorRepository {\n static getListPage(pageNumber, pageSize) {\n return gql`{\n allIndicators{\n nodes {\n id\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Enable tests for Safari 9"
},
{
"from": "human",
"value": "var argv = require('yargs').argv;\n\nmodule.exports = {\n registerHooks: function(context) {\n var saucelabsPlatforms = [\n 'macOS 10.12/iphone@10.3',\n 'macOS 10.12/ipad@10.3',\n 'Windows... | javascript | chosen |
[
{
"from": "system",
"value": "Fix test CustomDomainWrapper with mobilization is list\n"
},
{
"from": "human",
"value": "import React from 'react'\nimport TestUtils from 'react-addons-test-utils'\nimport { CustomDomainWrapper } from '../../pages/CustomDomainWrapper/CustomDomainWrapper'\nimport Sh... | javascript | chosen |
[
{
"from": "system",
"value": "Remove the fake video stream, add audio\n"
},
{
"from": "human",
"value": "$(document).ready(function () {\n var provider = new XMPPProvider({webrtc: {video: true, fake: true}});\n\n $('form').submit(function() {\n var jid = $('#jid').val();\n var pass = $('... | javascript | chosen |
[
{
"from": "system",
"value": "Remove debug from statsd config\n[skip-ci]\n"
},
{
"from": "human",
"value": "(function() {\n return {\n graphitePort: 2003\n , graphiteHost: \"carbon.hostedgraphite.com\"\n , port: 8125\n , debug: true\n , dumpMessages: true\n ,backends: [\"./bac... | javascript | chosen |
[
{
"from": "system",
"value": "Remove obsolete Authenticated component import/export\n"
},
{
"from": "human",
"value": "import Login from './Login'\nimport Purgatory from './Purgatory'\n\nimport {\n UserIsAuthenticated,\n Authenticated,\n UserIsNotAuthenticated,\n} from './Authenticated'\nexpo... | javascript | chosen |
[
{
"from": "system",
"value": "Revert \"Remove Backbone.Events.on() from server side. It conflicts with Node.js events\"\n\nThis reverts commit 2e14e8960d0e5e6248ffed58b90325b9729824de.\n"
},
{
"from": "human",
"value": "var Backbone = module.exports = require('../shared/backbone');\n\nBackbone.s... | javascript | chosen |
[
{
"from": "system",
"value": "Add filename to parent error og\n"
},
{
"from": "human",
"value": "\nif (document.location.hostname == \"localhost\") {\n var baseurl = \"\";\n} else {\n var baseurl = \"https://noconfidencevote.openup.org.za\";\n}\n\nfunction logError(e) {\n try {\n var s... | javascript | chosen |
[
{
"from": "system",
"value": "Add initial tests for Registry.once\n"
},
{
"from": "human",
"value": "import test from 'ava';\n\ntest.todo('Write test for Registry.once');\n"
},
{
"from": "gpt",
"value": "import test from 'ava';\nimport Registry from '../src/registry';\n\ntest('Regist... | javascript | chosen |
[
{
"from": "system",
"value": "Clarify error for LDAP users on try to reset password\n\n"
},
{
"from": "human",
"value": "let originalSendResetPasswordEmail = Accounts.sendResetPasswordEmail;\nAccounts.sendResetPasswordEmail = function (userId, email) {\n let user = Meteor.users.findOne(userId... | javascript | chosen |
[
{
"from": "system",
"value": "FIX is valid for invoice address\n"
},
{
"from": "human",
"value": "var ResourceService = require(\"services/ResourceService\");\n\nVue.component(\"invoice-address-select\", {\n\n template: \"<address-select template=\\\"#vue-address-select\\\" v-on:address-chang... | javascript | chosen |
[
{
"from": "system",
"value": "Fix indentation on js. Add execute example.\n"
},
{
"from": "human",
"value": "module.exports = {\n\t'GitHub example testing': function (test) {\n\ttest\n\t\t.open('https://github.com')\n\t\t.waitForElement('input[name=q]')\n\t\t.assert.title().is('GitHub · Build so... | javascript | chosen |
[
{
"from": "system",
"value": "Return a string if input is a string\n"
},
{
"from": "human",
"value": "// Returns a string representation of a kbdCommand\n// TODO: Need to get user's OS. If they are on a mac, replace instances of\n// ctrlKey with 'Cmd'.\nexport function kbdCommandToString({... | javascript | chosen |
[
{
"from": "system",
"value": "Rewrite mocha test case: 1. use normal function instead of arrow function\nto prevent this binding. 2. use async function to simplfy test\n"
},
{
"from": "human",
"value": "'use strict'\n\nimport md5 from '../lib/md5'\nimport fs from 'fs'\nimport { expect } from 'ch... | javascript | chosen |
[
{
"from": "system",
"value": "Make all value strings numbers, for real this time\n\ncloses #1\n[ci skip]\n"
},
{
"from": "human",
"value": "'use strict';\nvar MongoClient = require('mongodb').MongoClient;\n\nvar dbURL = process.env.MONGOLAB_URI || 'mongodb://localhost:27017/openAQ';\nvar measure... | javascript | chosen |
[
{
"from": "system",
"value": "Fix download and upload urls\n"
},
{
"from": "human",
"value": "'use strict';\n\nmodule.exports = {\n all: {\n method: 'GET',\n path: '/'\n },\n byName: {\n method: 'GET',\n path: '/:package'\n },\n add: {\n method: 'POST',\n path: '/'\n },\n... | javascript | chosen |
[
{
"from": "system",
"value": "Change mixin to use new package\n\nThis should not break anything, because the mixin essentially remains the\nsame.\n"
},
{
"from": "human",
"value": "'use strict';\n\nimport { Mixin } from 'mixwith/src/mixwith';\n\n/**\n * Dependencies symbol\n *\n * @type {Symbol}... | javascript | chosen |
[
{
"from": "system",
"value": "Improve service and error handling a bit\n"
},
{
"from": "human",
"value": "function SearchService ($http) {\n var omdbUrl = 'http://www.omdbapi.com/';\n var apiUrl = 'http://localhost:3020/';\n var Search = {};\n\n SearchService.loading = false;\n\n SearchServ... | javascript | chosen |
[
{
"from": "system",
"value": "Reset the border when calibrating\n\nIE9 has a gray border on about:blank which causes incorrect calibration.\n"
},
{
"from": "human",
"value": "(function(window) {\n /*jshint browser:true, node:false*/\n 'use strict';\n\n function createRedStripe(side) {\n... | javascript | chosen |
[
{
"from": "system",
"value": "Add MDX snapshotting to HTML example (failed)\n"
},
{
"from": "human",
"value": "const config = require('../../jest.config');\n\nmodule.exports = {\n ...config,\n roots: [__dirname],\n transform: {\n ...config.transform,\n '.*\\\\.(html)$': '<rootDir>/node_... | javascript | chosen |
[
{
"from": "system",
"value": "Remove code obsoleted by upgrading PostCSS\n"
},
{
"from": "human",
"value": "import _ from 'lodash'\nimport postcss from 'postcss'\n\nimport substituteTailwindAtRules from './lib/substituteTailwindAtRules'\nimport evaluateTailwindFunctions from './lib/evaluateTailw... | javascript | chosen |
[
{
"from": "system",
"value": "Add my-2 class in Sidebar component\n"
},
{
"from": "human",
"value": "import React from 'react';\n// import LazyLoad from 'react-lazyload';\n\nimport PropTypes from 'prop-types';\n\nimport './index.scss';\n\nconst Sidebar = ({ post }) => (\n <header className={`mx... | javascript | chosen |
[
{
"from": "system",
"value": "Use $(npm bin) to locate the babel binary\n"
},
{
"from": "human",
"value": "import {resolve} from \"path\";\nimport execSync from \"../services/exec-sync\";\nimport log from \"../services/logger\";\n\nexport default function compileSources ({bundleDir, sourceDir}) ... | javascript | chosen |
[
{
"from": "system",
"value": "Allow authentication through google plus\n"
},
{
"from": "human",
"value": "var express = require('express');\n\nvar app = express();\n\napp.get('/', function(req, res) {\n\n});\n\napp.get('/authenticate', function(req, res) {\n\n});\n\napp.get('/authenticate/callba... | javascript | chosen |
[
{
"from": "system",
"value": "Include popper.js and tooltip.js sourcemaps\n\nFixes #226\n"
},
{
"from": "human",
"value": "'use strict';\n\nmodule.exports = {\n name: 'ember-tooltips',\n\n options: {\n nodeAssets: {\n\n 'popper.js': {\n vendor: {\n srcDir: 'dist/umd',\n... | javascript | chosen |
[
{
"from": "system",
"value": "Change url scheme name to HTTP\n"
},
{
"from": "human",
"value": "'use strict';\nrequire('es6-promise').polyfill();\nrequire('whatwg-fetch');\n\nconst url = require('url'),\n querystring = require('querystring').parse;\n\nconst registry = 'http://npm-registry.h... | javascript | chosen |
[
{
"from": "system",
"value": "Use hdurl prop from NASA API response\n\n`hd` param appears to be obsolete, however there is an hdurl prop in\nthe response\n"
},
{
"from": "human",
"value": "const { nasaApiKey } = require('./nasa-api-key');\n\nexports.decorateConfig = (config) => {\n return Objec... | javascript | chosen |
[
{
"from": "system",
"value": "Remove main process only modules\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar webpack = require('webpack');\nvar JsonpTemplatePlugin = webpack.JsonpTemplatePlugin;\nvar FunctionModulePlugin = require('webpack/lib/FunctionModulePlugin');\nvar NodeTargetPlu... | javascript | chosen |
[
{
"from": "system",
"value": "Fix copy with absolute paths\n"
},
{
"from": "human",
"value": "var fse = require(\"fs-extra\");\n\nfunction WebpackCopyAfterBuildPlugin(mappings) {\n this._mappings = mappings || {};\n}\n\nWebpackCopyAfterBuildPlugin.prototype.apply = function(compiler) {\n var m... | javascript | chosen |
[
{
"from": "system",
"value": "Patch for an xss vulnerability where it was possible to inject js by closing and then opening a new script tag eg. ?q=\"xxxx'yyyy</script><script>confirm('hello')</script>&sa=Search\n"
},
{
"from": "human",
"value": "var React = require('react');\nvar ReactDOM = re... | javascript | chosen |
[
{
"from": "system",
"value": "Sort combination operators in alphabetical order\n"
},
{
"from": "human",
"value": "const constant = (base, value) => map(base, () => value)\n\nconst filter = (base, predicate) => next =>\n base(value => predicate(value) && next(value))\n\nconst from = values => ne... | javascript | chosen |
[
{
"from": "system",
"value": "Allow simply setting { fingerprint: false } as a shortcut option to disable"
},
{
"from": "human",
"value": "var path = require('path');\nvar fs = require('fs');\n\nvar assetRev = require('./lib/asset-rev');\n\nmodule.exports = {\n name: 'broccoli-asset-rev',\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Revert \"Use `npms.io` fetch packages\"\n\nThis reverts commit 94c3d7178c166c8ed3c5cf2df04eb5f55f1e49d4.\n"
},
{
"from": "human",
"value": "'use strict';\nconst got = require('got');\n\nmodule.exports = username => {\n\tif (typeof username !== 'string') {\n\t\tretur... | javascript | chosen |
[
{
"from": "system",
"value": "Update David Molina's role on landing page\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport LinkButton from 'shared/components/linkButton/linkButton';\nimport commonUrl from 'shared/constants/commonLinks';\nimport styles from './hero.css';\n\nco... | javascript | chosen |
[
{
"from": "system",
"value": "Add identicon icon_url to sendToSlack"
},
{
"from": "human",
"value": "var _ = require('lodash');\nvar logger = require('winston');\nvar request = require('superagent');\n\nfunction SlackGateway(incomingURL, channelMapping) {\n this.incomingURL = incomingURL;\n th... | javascript | chosen |
[
{
"from": "system",
"value": "Add time to anniversary display.\n"
},
{
"from": "human",
"value": "import React from 'react';\n\nimport css from './styles.css';\n\nexport default function Wedding() {\n return (<div className={css.container}>\n <h1>Sylvia and Nick</h1>\n <h3>We are now marr... | javascript | chosen |
[
{
"from": "system",
"value": "Add nodejs 12.x to supported runtimes\n"
},
{
"from": "human",
"value": "// native runtime support for AWS\n// https://docs.aws.amazon.com/lambda/latest/dg/lambda-runtimes.html\n\n// .NET CORE\nexport const supportedDotnetcore = new Set([\n // deprecated\n // 'dot... | javascript | chosen |
[
{
"from": "system",
"value": "Move export statement to bottom of file\n"
},
{
"from": "human",
"value": "/**\n * The entry point of the entire application\n * @class App\n */\nexport default class App {\n sanity() {\n return true;\n }\n}\n"
},
{
"from": "gpt",
"value": "/**\n * ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix a minor bootstrap UI issue\n"
},
{
"from": "human",
"value": "var getThat = {};\n\ngetThat.controller = function() {\n\n};\n\ngetThat.header = function() {\n return m('.row', [\n m('.col-md-10', [\n m('.jumbotron', [\n m('h1',... | javascript | chosen |
[
{
"from": "system",
"value": "Enable google analytics on all pages\n"
},
{
"from": "human",
"value": "var thirdParty = require('./thirdparty.js');\nthirdParty.setupRollbar();\nthirdParty.setupLogfit();\nthirdParty.setupSegment();\nthirdParty.setupVarsnap();\nrequire('./global.js');\n\nvar calcul... | javascript | chosen |
[
{
"from": "system",
"value": "Add route to list pages\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar express = require('express')\n , bodyParser = require('body-parser')\n , mongoose = require('mongoose')\n , cors = require('./cors')\n , app = express();\n\nrequire('./models/click')... | javascript | chosen |
[
{
"from": "system",
"value": "Correct use of findOne here\n"
},
{
"from": "human",
"value": "Router.configure({\n layoutTemplate: 'layout',\n loadingTemplate: 'loading',\n notFoundTemplate: 'notFound',\n waitOn: function() { return Meteor.subscribe('posts'); }\n});\n\nRouter.route('/', {name... | javascript | chosen |
[
{
"from": "system",
"value": "Refactor api into a react class\n"
},
{
"from": "human",
"value": "/**\n * @providesModule react-native-digits\n * @flow\n */\n'use strict';\n\nvar { NativeModules } = require('react-native');\nvar NativeRNDigits = NativeModules.RNDigits;\nvar invariant = require('i... | javascript | chosen |
[
{
"from": "system",
"value": "Revert \"Remove babel-compiler dependency in minifier-js\"\n\nThis reverts commit 7aa447ff9aa381bc4bee5fff1f02e9625f0bbfe0.\n"
},
{
"from": "human",
"value": "Package.describe({\n summary: \"JavaScript minifier\",\n version: \"2.6.1\"\n});\n\nNpm.depends({\n ters... | javascript | chosen |
[
{
"from": "system",
"value": "Add 'use strict' option to panel directive\n"
},
{
"from": "human",
"value": "\n(function(){\n angular\n .module('everycent.common')\n .directive('ecPanel', ecPanel);\n\n function ecPanel(){\n var directive = {\n restrict:'E',\n templateUrl: 'ap... | javascript | chosen |
[
{
"from": "system",
"value": "Reduce duplication in acceptance tests\n"
},
{
"from": "human",
"value": "import { expect } from 'chai';\nimport { addTodo } from './common.js';\n\n\ndescribe('App', function() {\n beforeEach(function() {\n addTodo('buy cheddar');\n addTodo('buy chorizo');\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Set defaultProp for Accordion's children\n"
},
{
"from": "human",
"value": "// @flow\n\nimport React, { Component, type Node } from 'react';\nimport { Provider } from 'mobx-react';\nimport { createAccordionStore } from '../accordionStore/accordionStore';\n\ntype Acc... | javascript | chosen |
[
{
"from": "system",
"value": "Remove default params for fetchThread\n"
},
{
"from": "human",
"value": "import Axios from 'axios';\nimport {\n THREAD_REQUEST, \n THREAD_LOADED, \n THREAD_DESTROY,\n THREAD_POST_LOAD\n} from '../constants';\n\n\nfunction requestThread(threadID) {\n\tcon... | javascript | chosen |
[
{
"from": "system",
"value": "Move call to module scope\n"
},
{
"from": "human",
"value": "'use strict';\n\n// MODULES //\n\nvar keys = require( 'object-keys' );\nvar isPlainObject = require( '@stdlib/utils/is-plain-object' );\nvar hasSymbolSupport = require( '@stdlib/utils/detect-symbol-support... | javascript | chosen |
[
{
"from": "system",
"value": "Add clears to common declarations"
},
{
"from": "human",
"value": "\nconst commonDeclarations = {\n boxSizing: [\n 'border-box'\n ],\n\n display: [\n 'block',\n 'inline-block',\n 'inline',\n 'table',\n 'table-cell',\n 'none'\n ],\n\n float:... | javascript | chosen |
[
{
"from": "system",
"value": "Add a rule for decimal numbers.\n\nTo be used in AlbumEdit.\n\nRefs #78.\n"
},
{
"from": "human",
"value": "export function mandatory(comp) {\n\treturn v => !!v || comp.$t('validation.mandatory')\n}\n\nfunction regexMatch(comp, regex, key) {\n\treturn v => {\n\t\tif... | javascript | chosen |
[
{
"from": "system",
"value": "Tweak date format to show month with letters\n"
},
{
"from": "human",
"value": "'use strict';\nconst dateFormat = require('dateformat');\n\nconst settings = require('./../settings.js');\n\nconst propertyKey = settings.get('propertyKey');\nconst maxResults = settings... | javascript | chosen |
[
{
"from": "system",
"value": "[Tests] Add process.exit() call when nodemon quits\n"
},
{
"from": "human",
"value": "/* eslint-disable no-console */\nimport Nodemon from 'nodemon';\n\nNodemon({\n args: process.argv,\n script: 'test/unit.js',\n execMap: {js: 'node_modules/.bin/babel-node'},\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Add date to the day.show route URI\n"
},
{
"from": "human",
"value": "Energy = Ember.Application.create();\n\nEnergy.Router.map(function() {\n this.resource(\"day\", function() {\n this.route(\"show\");\n });\n});\n\nEnergy.IndexRoute = Ember.Route.exte... | javascript | chosen |
[
{
"from": "system",
"value": "Load Ajax Library before loading sharepoint libraries\n"
},
{
"from": "human",
"value": "angular\n .module('ngSharepoint', [])\n .run(['$sp', '$spLoader', function($sp, $spLoader) {\n if ($sp.getAutoload()) {\n if ($sp.getConnectionMode() ===... | javascript | chosen |
[
{
"from": "system",
"value": "Change Canvas api to use queued get\n"
},
{
"from": "human",
"value": "import _ from 'lodash';\nimport Api from './api';\n\nfunction proxyUrl(url){\n return `api/canvas?url=${encodeURIComponent(url)}`;\n}\n\nfunction get_next_url(link){\n if(link){\n co... | javascript | chosen |
[
{
"from": "system",
"value": "Add option spec (i.e., enable usage in Resonant Laboratory)\n"
},
{
"from": "human",
"value": "import Geo from '../Geo';\nimport VisComponent from '../../VisComponent';\n\nexport default class GeoDots extends VisComponent {\n constructor (el, options) {\n super(... | javascript | chosen |
[
{
"from": "system",
"value": "Remove rule for processing styles from webpack configuration\n"
},
{
"from": "human",
"value": "const webpack = require('webpack')\nconst merge = require('webpack-merge')\nconst HtmlWebpackPlugin = require('html-webpack-plugin')\nconst ExtractTextPlugin = require('e... | javascript | chosen |
[
{
"from": "system",
"value": "Update to include the latest web platform tests\n\nIncludes https://github.com/w3c/web-platform-tests/pull/5792.\n"
},
{
"from": "human",
"value": "\"use strict\";\n\nif (process.env.NO_UPDATE) {\n process.exit(0);\n}\n\nconst path = require(\"path\");\nconst fs = ... | javascript | chosen |
[
{
"from": "system",
"value": "Use run-series and refactor job\n"
},
{
"from": "human",
"value": "const Logger = require('franston')('jobs/update-cache')\n\nconst GithubActivity = require('../models/github-activity')\nconst GithubCache = require('../models/github-cache')\nconst Recurse = require(... | javascript | chosen |
[
{
"from": "system",
"value": "Fix issue where a parent was null, possibly from a node that was already patched.\n"
},
{
"from": "human",
"value": "import dom from '../vdom/dom';\nimport realNode from '../util/real-node';\n\nexport default function (src, dst) {\n const realNodeSrc = realNode(src... | javascript | chosen |
[
{
"from": "system",
"value": "Move editor-related setup into event handler so it only runs after the editor has been initialized\n"
},
{
"from": "human",
"value": "(function(){\n\nzeit.cms.declare_namespace('zeit.edit');\n\n\nzeit.edit.FoldBlock = gocept.Class.extend({\n\n construct: function... | javascript | chosen |
[
{
"from": "system",
"value": "Update to set dates from this year.\n"
},
{
"from": "human",
"value": "import Ember from 'ember';\n\nexport default Ember.Route.extend({\n setupController: function(controller) {\n controller.set('project', 'reflect-productivity');\n controller.set('viewName'... | javascript | chosen |
[
{
"from": "system",
"value": "Add shortname property to <DisqusThread>\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport Icon from 'react-fontawesome';\nimport Markdown from 'react-markdown';\nimport DisqusThread from 'react-disqus-thread';\nimport { toHumanReadableDate } fro... | javascript | chosen |
[
{
"from": "system",
"value": "Sort subtitles and prevent duplicates\n"
},
{
"from": "human",
"value": "const Extractor = remote.require('./browser/index.js');\nconst Subtitles = remote.require('./browser/model/Subtitle.js');\nconst shell = remote.shell;\n\napp.controller('SubtitleListController'... | javascript | chosen |
[
{
"from": "system",
"value": "Implement various loop nodes (listed below).\n\nForInStatement\nDoWhileStatement\nLabeledStatement\nContinueStatement\nBreakStatement\n"
},
{
"from": "human",
"value": "// for (init; test; update) body\nexports.ForStatement = (node, generator) => {\n generator.adva... | javascript | chosen |
[
{
"from": "system",
"value": "Fix bug where devices didn't close if stayOpen was true\n"
},
{
"from": "human",
"value": "// This source file is part of the Packet Guardian project.\n// Use of this source code is governed by a BSD-style\n// license that can be found in the LICENSE file.\n$.onRead... | javascript | chosen |
[
{
"from": "system",
"value": "Fix bug with areas without textures\n"
},
{
"from": "human",
"value": "import Three from 'three';\n\nexport default function createArea(vertices, color, textureName) {\n\n let shape = new Three.Shape();\n shape.moveTo(vertices[0].x, vertices[0].y);\n for (let i =... | javascript | chosen |
[
{
"from": "system",
"value": "Update library reference to fix last commit\n"
},
{
"from": "human",
"value": "const createClient = require('rabblerouser-stream-client');\nconst config = require('./config');\n\nconst streamClientSettings = {\n publishToStream: config.eventStream.streamName,\n li... | javascript | chosen |
[
{
"from": "system",
"value": "Add safety check when filling\n"
},
{
"from": "human",
"value": "/* globals TileTools */\n(class Bucket extends DTile.Tool {\n static get toolName() { return \"bucket\"; }\n static get icon() { return \"tool:bucket\"; }\n\n onMove(e) {\n this._previe... | javascript | chosen |
[
{
"from": "system",
"value": "fix: Use --disabled class for disabled switch\n"
},
{
"from": "human",
"value": "import {PlainViewModel} from './mdc-knockout-base'\n\nexport default class SwitchViewModel extends PlainViewModel {\n extend () {\n if (!this.attrs['id']) {\n this.attrs['id'] ... | javascript | chosen |
[
{
"from": "system",
"value": "Add state to provide that the hot reload is working with state retention\n"
},
{
"from": "human",
"value": "import React, { Component } from 'react';\nimport jQuery from 'jquery';\nimport wut from 'wut.css';\n\nexport default class App extends Component {\n rende... | javascript | chosen |
[
{
"from": "system",
"value": "Fix relative import to be absolute\n"
},
{
"from": "human",
"value": "import d3 from 'd3';\nimport fcRebind from 'd3fc-rebind';\nimport {getStockFluxData} from '../../../../../../node_modules/stockflux-core/src/services/StockFluxService';\n\nexport default function(... | javascript | chosen |
[
{
"from": "system",
"value": "Fix end to end test\n"
},
{
"from": "human",
"value": "describe('Get a user to login and show dashboard:', function() {\n it('should let a user login', function() {\n driver = browser.driver;\n\n driver.get(browser.params.live_server_url + 'login/')... | javascript | chosen |
[
{
"from": "system",
"value": "Set withCredentials flag on requests\n"
},
{
"from": "human",
"value": "const tokenHeader = 'Sanity-Token'\nconst projectHeader = 'Sanity-Project-ID'\n\nexports.getRequestOptions = config => {\n const headers = {}\n\n if (config.token) {\n headers[tokenHeader] ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix issue with multiple loads\n\nNow blocking and returning the previous promise when a request comes while the data is still being searched for.\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar bowlingApp = angular.module('bowling', ['ngRoute']);\n\nbowlingA... | javascript | chosen |
[
{
"from": "system",
"value": "Fix printing the state graph svg\n\nRelated to https://github.com/gaearon/redux-devtools/issues/318\n"
},
{
"from": "human",
"value": "import React, { Component, PropTypes } from 'react';\nimport PrintIcon from 'react-icons/lib/md/print';\nimport Button from '../But... | javascript | chosen |
[
{
"from": "system",
"value": "Sort recipients by group/label priorities and then by label\n\n"
},
{
"from": "human",
"value": "/*jslint browser: true, undef: true, white: false, laxbreak: true *//*global Ext,Slate*/\nExt.define('SlateAdmin.store.people.progress.NoteRecipients', {\n extend: 'E... | javascript | chosen |
[
{
"from": "system",
"value": "Update URL to work correctly.\n"
},
{
"from": "human",
"value": "import * as types from './ActionTypes'\nimport axios from 'axios'\n\nexport function addPattern(name, pattern) {\n return {\n type: types.ADD_PATTERN,\n name: name,\n pattern: pattern\n }\n}... | javascript | chosen |
[
{
"from": "system",
"value": "Update error output in CLI\n"
},
{
"from": "human",
"value": "#!/usr/bin/env node\nvar fs = require('fs')\nvar path = require('path')\n\nvar cli = require('../lib/cli')\n\ncli(process.stdin, process.stdout, process.argv.slice(2), function (err, args) {\n if (err) {... | javascript | chosen |
[
{
"from": "system",
"value": "Improve error handling on PG connection\n"
},
{
"from": "human",
"value": "var pg = require('pg');\n\nfunction insertTemp(temp) {\n pg.connect(process.env.DATABASE_URL, function(err, client) {\n if (err) throw err;\n\n client.query('INSERT INTO temperature (d... | javascript | chosen |
[
{
"from": "system",
"value": ":zap: Update connect HOC to use proper lifecycle method\n"
},
{
"from": "human",
"value": "import React, { Component } from 'react';\n\n/**\n * Gets display name of the component.\n *\n * @param {Component} WrappedComponent React component\n * @return {String} ... | javascript | chosen |
[
{
"from": "system",
"value": "Use trackErrors option of piwik-react-router\n"
},
{
"from": "human",
"value": "// App config the for production environment.\n// Do not require this directly. Use ./src/config instead.\n\nconst HOST = process.env.HOST || \"api.openfisca.fr\",\n apiBaseUrl = proces... | javascript | chosen |
[
{
"from": "system",
"value": "Clean up example config a bit\n"
},
{
"from": "human",
"value": "/* export anthracite */\nvar anthracite = {\n // Uncomment and add your firebase URL\n // firebase : \"https://<YOUR-APP-HERE>.firebaseio.com/\"\n \n // Other config params\n \n // Au... | javascript | chosen |
[
{
"from": "system",
"value": "Fix botched React default require in bundled module\n\nTurns out you shouldn't mix `import React …` and `import * as React …`!\n"
},
{
"from": "human",
"value": "import * as React from 'react';\nimport Radium from 'radium';\n\ntype SpanT = {\n span: 1 | 2 | 3 | 4 |... | javascript | chosen |
[
{
"from": "system",
"value": "Fix a webpack plugin for production\n"
},
{
"from": "human",
"value": "const path = require('path');\nconst webpack = require('webpack');\n\nconst { isDevelopment, isTest } = require('../configuration');\n\nconst HtmlWebpackPlugin = require('html-webpack-plugin');\n... | javascript | chosen |
[
{
"from": "system",
"value": "Set border color to match text color.\n"
},
{
"from": "human",
"value": "import Ember from 'ember';\nexport default Ember.Component.extend({\n firstName: '',\n lastName: '',\n company: '',\n firstInitial: (function() {\n return this.get(\"firstName\")[0] || t... | javascript | chosen |
[
{
"from": "system",
"value": "Add logic for Rook horiz movement, can't take own pieces.\n"
},
{
"from": "human",
"value": "var rookAction = function() {\n\t$( \".white-square, .black-square\" ).droppable({\n\t\tactiveClass: \"ui-state-hover\",\n\t\thoverClass: \"ui-state-active\",\n\t\t\n\t\tdro... | javascript | chosen |
[
{
"from": "system",
"value": "Change reporter to junit reporter\n"
},
{
"from": "human",
"value": "module.exports = {\n networks: {\n development: {\n host: \"localhost\",\n port: 8545,\n network_id: \"*\" // Match any network id\n }\n }\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Return url root when no id exists\n"
},
{
"from": "human",
"value": "\"use strict\";\n/**\n * Model for individual books.\n */\n define([\n \"underscore\",\n \"backbone\"\n], function(_, Backbone) {\n var Book = Backbone.Model.extend({\n idAttribute:... | javascript | chosen |
[
{
"from": "system",
"value": "Update style of coverage reporter to be more ES6 like\n\nExtend the coverage reporter from the mocha spec reporter\n"
},
{
"from": "human",
"value": "const istanbulAPI = require('istanbul-api');\nconst libCoverage = require('istanbul-lib-coverage');\n\nfunction Ista... | javascript | chosen |
[
{
"from": "system",
"value": "Rename summernote to context in module.\n"
},
{
"from": "human",
"value": "define([], function () {\n var HelpDialog = function (summernote) {\n var self = this;\n var ui = $.summernote.ui;\n\n var $editor = summernote.layoutInfo.editor;\n var options =... | javascript | chosen |
[
{
"from": "system",
"value": "feat(login): Set monitoring as the default page after login (SDNTB-180)\n"
},
{
"from": "human",
"value": "/**\n * This file is part of Superdesk.\n *\n * Copyright 2013, 2014 Sourcefabric z.u. and contributors.\n *\n * For the full copyright and license information... | javascript | chosen |
[
{
"from": "system",
"value": "Fix test for sub components\n"
},
{
"from": "human",
"value": "const React = require('react')\nconst should = require('should')\nconst { shallow } = require('enzyme')\nconst { expect } = require('chai')\n\nimport DropdownAlert from '../DropdownAlert'\nimport {\n Vi... | javascript | chosen |
[
{
"from": "system",
"value": "Handle errors from agile source\n"
},
{
"from": "human",
"value": "/* jshint browser: true, jquery: true */\n/* global AgileSprint:false, console:false */\n\n\nvar AgileSprintManager = function(options) {\n// if(options.server === null || options.server === undefin... | javascript | chosen |
[
{
"from": "system",
"value": "Add allow insert and update rules\n"
},
{
"from": "human",
"value": "Invitations = new Mongo.Collection(\"invitations\");\n\nInvitationsSchema = new SimpleSchema({\n emails: {\n type: [String],\n label: \"E-mail address\",\n regEx: SimpleSchema.RegEx.Email... | javascript | chosen |
[
{
"from": "system",
"value": "feat(styleguide): Document Toggle checked prop in styleguide\n\n[#114690205]\n"
},
{
"from": "human",
"value": "/*doc\n---\ntitle: Toggle\nname: toggle_react\nparent: form_react\n---\n\n<code class=\"pam\">\n <i class=\"fa fa-download\" alt=\"Install the Component\... | javascript | chosen |
[
{
"from": "system",
"value": "Check user before checking for firstName.\n"
},
{
"from": "human",
"value": "/**\n * Dashboard\n */\n\nTemplate.dashboard.helpers({\n firstName() {\n if (Meteor.userId()) {\n return Meteor.user().profile.name.split(' ')[0];\n }\n return '';\n },\n c... | javascript | chosen |
[
{
"from": "system",
"value": "Update google analytics page tracking\n"
},
{
"from": "human",
"value": "\"use strict\";\n\nvar GoogleAnalytics = {};\n\nGoogleAnalytics.TrackNavigation = function() {\n ga(\"send\", \"pageview\");\n};\n\nmodule.exports = GoogleAnalytics;"
},
{
"from": "gpt... | javascript | chosen |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.