conversations listlengths 2 3 | source stringclasses 1
value | stack stringclasses 1
value |
|---|---|---|
[
{
"from": "system",
"value": "Update grunt file to run coverage files\n"
},
{
"from": "human",
"value": "'use strict';\n\nmodule.exports = function(grunt) {\n\n grunt.initConfig({\n pkg: grunt.file.readJSON('package.json'),\n jshint: {\n allFiles: ['Gruntfile.js', 'li... | javascript | chosen |
[
{
"from": "system",
"value": "Make grunt build only for your platform\n"
},
{
"from": "human",
"value": "module.exports = function(grunt) {\n\n grunt.initConfig({\n nodewebkit: {\n options: {\n\n version: 'v0.12.0',\n files: './app/*',\n downloadUrl: 'http://dl.nwjs... | javascript | chosen |
[
{
"from": "system",
"value": "Add dev task to report on any todos noted in code.\n"
},
{
"from": "human",
"value": "/**\n * Gruntfile.js\n *\n * Development and build tasks for\n * the QClient module.\n */\n\nmodule.exports = function(grunt) {\n var hashFiles = require('hash-files');\n\n requi... | javascript | chosen |
[
{
"from": "system",
"value": "Make sure all package files are committed correctly when bumping a version"
},
{
"from": "human",
"value": "module.exports = function(grunt) {\n\n // Project configuration.\n grunt.initConfig({\n pkg: grunt.file.readJSON('package.json'),\n uglify: {\n o... | javascript | chosen |
[
{
"from": "system",
"value": "Allow grunt-jekyll to build drafts\n"
},
{
"from": "human",
"value": "module.exports = function (grunt) {\n // load all grunt tasks matching the `grunt-*` pattern\n require('load-grunt-tasks')(grunt);\n\n grunt.initConfig({\n\n autoprefixer: {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Add proptypes & signedIn check to navbar\n"
},
{
"from": "human",
"value": "import React, { PureComponent } from 'react'\nimport { connect } from 'react-redux'\nimport { Link } from 'react-router'\n\nimport signOut from '../../actions/users/sign-out'\n\nclass Navbar... | javascript | chosen |
[
{
"from": "system",
"value": "[select] Add onChange as an option of the field (corelated selects).\n"
},
{
"from": "human",
"value": "var {isObject, isFunction} = require('lodash/lang');\n\nvar valueBehaviourMixin = {\n /** @inheritdoc */\n getDefaultProps: function getDefaultValueBehaviourPro... | javascript | chosen |
[
{
"from": "system",
"value": "Make scenarios pass in both Cucumber and Cucumber-Electron\n"
},
{
"from": "human",
"value": "const fs = require('fs')\nconst path = require('path')\n\nconst { setWorldConstructor } = require('cucumber')\nconst TodoList = require('../../lib/TodoList')\nconst mountBr... | javascript | chosen |
[
{
"from": "system",
"value": "Remove % wrappers for node environment variables, fix forEach print to only print first argument.\n"
},
{
"from": "human",
"value": "var fs = require('fs');\n\nvar environmentVariables = [\n \"WEBSITE_SITE_NAME\",\n \"WEBSITE_SKU\",\n \"WEBSITE_COMPUTE_MODE... | javascript | chosen |
[
{
"from": "system",
"value": "Remove old unused JS and debugging\n"
},
{
"from": "human",
"value": "$(document).ready(function() {\n // HACK: Setting Recommended Status via AJAX Call\n // $.get('/watchlist/status/' + $('#event_id').val(), function(data) {\n // if(data) {\n // $('#watc... | javascript | chosen |
[
{
"from": "system",
"value": "Allow user styles to override default styles\n\nJust moved the `...styles` spread to the end of the style object."
},
{
"from": "human",
"value": "\nimport React from 'react';\nimport PropTypes from 'prop-types';\n\nimport SvgIcon from './SvgIcon';\n\nexport const I... | javascript | chosen |
[
{
"from": "system",
"value": "Update record temperature to use the stored sensors\n"
},
{
"from": "human",
"value": "var ds18b20 = require('ds18b20');\nvar crontab = require('node-crontab');\nvar config = require('../config.json');\nvar logger = require('./logger.js');\n\nfunction recordTemper... | javascript | chosen |
[
{
"from": "system",
"value": "Use the same node binary to run the workflow tests.\n"
},
{
"from": "human",
"value": "var argv = require('minimist')(process.argv.slice(2));\n\nvar processArgs = function() {\n var fileArg = argv._;\n\n var noFile = function() {\n return (fileArg.length === 0)... | javascript | chosen |
[
{
"from": "system",
"value": "Change presence clientId to _cookieId in client object\n"
},
{
"from": "human",
"value": "const program = require('commander');\n\nprogram\n .version('1.0.0')\n .option('-p, --port <port>', 'specify the websocket port to listen to [9870]', 9870)\n .parse(pr... | javascript | chosen |
[
{
"from": "system",
"value": "Use envs, not cmdline args."
},
{
"from": "human",
"value": "/*\n aad-login.js\n Requests a token from Azure AD using username/password\n\n Available under the Apache 2.0 License\n*/\n\n// Configuration parameters\nvar directory = '';\nvar clientid = '';\n\nif (... | javascript | chosen |
[
{
"from": "system",
"value": ":bug: Fix merging of inline+config entry\n"
},
{
"from": "human",
"value": "// @flow\n\nimport { PundleError, type Context } from 'pundle-api'\nimport type { Config, AcceptedConfig } from './types'\nimport readConfigFile from './readConfigFile'\nimport validateAndTr... | javascript | chosen |
[
{
"from": "system",
"value": "Add tests describing public API\n"
},
{
"from": "human",
"value": "const assert = require(`assert`) // node.js core module\n\nconst transform = require(`../src/transform`)\n\nconst testData = require(`./test-data`)\n\ndescribe(`Package`, () => {\n describe(`Transfo... | javascript | chosen |
[
{
"from": "system",
"value": "Update test suite. Works great :rainbows:\n"
},
{
"from": "human",
"value": "describe('Landing page', function() {\n it('should have the correct title', function(done, server, client) {\n var title = client.evalSync(function() {\n var titleText = $('title')... | javascript | chosen |
[
{
"from": "system",
"value": "Add gateway token header for health check\n\n"
},
{
"from": "human",
"value": "const config = require('../config.js');\nconst {getCollection} = require('./dataAccess/dbMethods');\nconst logger = require('../../log.js');\n\nconst url = require('url');\nconst superage... | javascript | chosen |
[
{
"from": "system",
"value": "Increase timeout for mocha tests.\n\nTravis machine speed can be flaky sometimes. This ensures we don't\nfail due to a timeout.\n"
},
{
"from": "human",
"value": "module.exports = function( grunt ) {\n grunt.initConfig({\n pkg: grunt.file.readJSON( \"package.jso... | javascript | chosen |
[
{
"from": "system",
"value": "Use browser test file with grunt connect\n"
},
{
"from": "human",
"value": "module.exports = function(grunt) {\n grunt.initConfig({\n pkg: grunt.file.readJSON('package.json'),\n bower: grunt.file.readJSON('bower.json'),\n uglify: {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Add index.js to the tests / complexity runner\n\nSigned-off-by: Henrique Vicente <d390f26e2f50ad5716a9c69c58de1f5df9730e3b@gmail.com>\n"
},
{
"from": "human",
"value": "/*\n * grunt-cli-config\n * https://github.com/henvic/grunt-cli-config\n *\n * Copyright (c) 2014... | javascript | chosen |
[
{
"from": "system",
"value": "Tidy up amazon associate JavaScript code\n"
},
{
"from": "human",
"value": "'use strict';\n\ndocument.addEventListener('DOMContentLoaded', () => {\n const regexp = /(?:ISBN|ASIN)=([0-9A-Z]+)/g;\n const COMMENT_NODE = 8;\n const bodies = document.querySelectorAll(... | javascript | chosen |
[
{
"from": "system",
"value": "Remove underscore and replace by ember functions\n"
},
{
"from": "human",
"value": "var keyCode = {\n 8: 'Backspace',\n 9: 'Tab',\n 13: 'Enter',\n 16: 'Shift',\n 17: 'Control',\n 18: 'Alt',\n 20: 'CapsLock',\n 27: 'Esc',\n 32: 'Space',\n 33: 'PageUp',\n 3... | javascript | chosen |
[
{
"from": "system",
"value": "Reset state for new game\n"
},
{
"from": "human",
"value": "import {\n NEW_GAME,\n PLAY_WITH_RED,\n PLAY_WITH_YELLOW,\n} from '../actions/connect4';\n\nimport Board from '../domain/board';\n\nexport const RED_TURN = 1;\nexport const YELLOW_TURN = 2;\n\n\nconst in... | javascript | chosen |
[
{
"from": "system",
"value": "Fix wrong property deleting - not clearing games\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar mongoose = require('mongoose');\nvar GamesController = require('./app/controllers/games.js');\nvar io = require('socket.io').listen(3000, '0.0.0.0');\nvar State ... | javascript | chosen |
[
{
"from": "system",
"value": "Rename folers, convert to lowercase\n"
},
{
"from": "human",
"value": "/*Config*/\nvar concat = require( 'gulp-concat' );\nvar gulp = require( 'gulp' );\nvar rename = require( 'gulp-rename' );\nvar runSequence = require( 'run-sequence' );\nvar sourceMaps = require( ... | javascript | chosen |
[
{
"from": "system",
"value": "Update TypeScript task to use tsc command line\n"
},
{
"from": "human",
"value": "/**\n * Created by Chance Snow on 12/7/14.\n */\n\nvar gulp = require('gulp');\nvar del = require('del');\nvar path = require('path');\nvar compass = require('gulp-for-compass');\nvar ... | javascript | chosen |
[
{
"from": "system",
"value": "Remove v-Button class from search-text clear button\n"
},
{
"from": "human",
"value": "import { Class } from '../../core/Core';\nimport ButtonView from './ButtonView';\n\nconst ClearSearchButtonView = Class({\n\n Extends: ButtonView,\n\n type: 'v-ClearSearchBu... | javascript | chosen |
[
{
"from": "system",
"value": "Remove specific path for Travis\n"
},
{
"from": "human",
"value": "'use strict';\n\n/**\n * This file contains the variables used in other gulp files\n * which defines tasks\n * By design, we only put there very generic config values\n * which are used in sever... | javascript | chosen |
[
{
"from": "system",
"value": "Delete global cache from memory\n"
},
{
"from": "human",
"value": "require('isomorphic-fetch');\n\nimport React from 'react';\nimport Router from 'react-router';\n\nimport {Resolver} from 'react-resolver';\nimport routes from '../routes';\n\nRouter.run(routes, Route... | javascript | chosen |
[
{
"from": "system",
"value": "Allow tests to run in more browsers by avoiding use of String.prototype.includes\n"
},
{
"from": "human",
"value": "export default function text ({ wrapper, markup, flag, arg1, sig }) {\n const actual = wrapper.text()\n\n if (undefined !== arg1) {\n if (flag(th... | javascript | chosen |
[
{
"from": "system",
"value": "Add support for toll free numbers\n\nCloses #7\n"
},
{
"from": "human",
"value": "const { GraphQLScalarType } = require('graphql')\nconst phone = require('phone')\n\n// Index 0 is phone, index 1 is country code\nmodule.exports = new GraphQLScalarType({\n name: 'Pho... | javascript | chosen |
[
{
"from": "system",
"value": "Add a missing trailing slash\n"
},
{
"from": "human",
"value": "(function() {\n chrome.contextMenus.create({\n \"id\": \"quick_rurema_search\",\n \"type\": \"normal\",\n \"title\": \"Quickるりまサーチ\",\n \"contexts\": [\"selection\"]\n });\n chrome.contex... | javascript | chosen |
[
{
"from": "system",
"value": "Split taxonomy/term into list of terms (names) and list of nodes (with term).\n"
},
{
"from": "human",
"value": "angular.module('drupalService', ['ngResource'])\n\n .factory('Node', ['$resource', function ($resource) {\n return $resource('/node/:nid', {nid... | javascript | chosen |
[
{
"from": "system",
"value": "Fix bug in file redirection\n"
},
{
"from": "human",
"value": "const path = require('path');\nconst express = require('express');\nconst { name, version, directories } = require('../package.json');\n\nconst app = express();\n\nconst staticPath = path.join(__dirname,... | javascript | chosen |
[
{
"from": "system",
"value": "Fix some small issues in board creation\n"
},
{
"from": "human",
"value": "var Cell = require(\"./Cell\");\n\nfunction Board(boardString) {\n this.board = boardString.split().map(function(e) {new Cell(e == 'X')});\n}\n\nBoard.prototype.fire = function(x, y) {\n th... | javascript | chosen |
[
{
"from": "system",
"value": "Check for globally installed binary\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar BinWrapper = require('bin-wrapper');\nvar path = require('path');\nvar pkg = require('../package.json');\n\n/**\n * Variables\n */\n\nvar BIN_VERSION = '0.7.5';\nvar BASE_URL... | javascript | chosen |
[
{
"from": "system",
"value": ":new: Add a fully though about declaration type\n"
},
{
"from": "human",
"value": "'use babel'\n\n/* @flow */\n\nimport type {TextEditorMarker, TextEditor, Range} from 'atom'\n\nexport type Provider = {\n grammarScopes: Array<string>,\n getDeclarations: ((params: ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix URL in new message notification\n"
},
{
"from": "human",
"value": "(function($){\n\tvar $bar;\n\twindow.xeNotifyMessage = function(text, count){\n\t\t$bar = $('div.message.info');\n\t\tif(!$bar.length) {\n\t\t\t$bar = jQuery('<div class=\"message info\"></div>')... | javascript | chosen |
[
{
"from": "system",
"value": "Update event for update address\n"
},
{
"from": "human",
"value": "function enterAddress() {\n $(\"#address\").keyup(function(event){\n if(event.keyCode == 13){\n $(\"button#address_submit\").click();\n }\n });\n\n $(\"#lower_address\").keyup(function(... | javascript | chosen |
[
{
"from": "system",
"value": "Add alternate image extensions webp and bmp to core sync script\n"
},
{
"from": "human",
"value": "/* global config, fs */\n\nmodule.exports = function(grunt) {\n\tgrunt.registerTask('syncDirectory', function(task) {\n\t\tif (task === 'fonts') {\n\t\t\tvar glob = re... | javascript | chosen |
[
{
"from": "system",
"value": "Add WebSocket client placeholder state.\n\nIf two clients connect to the server at the same time, a race condition\nmay occur where they have the same id. Instead of assigning client ids\non the first client state message, we assign ids on connect.\n"
},
{
"from": "huma... | javascript | chosen |
[
{
"from": "system",
"value": ":bug: Fix a flow warning\nFlow does not support the unicode flag with RegExpes yet\n"
},
{
"from": "human",
"value": "'use babel'\n\n/* @flow */\n\nimport type { Message, MessageLegacy } from '../types'\n\nexport function visitMessage(message: Message | MessageLegac... | javascript | chosen |
[
{
"from": "system",
"value": "Remove delete portion endpoint from api\n"
},
{
"from": "human",
"value": "'use strict';\n\nconst passport = require('passport');\nconst main = require('../app/controllers/main');\nconst api = require('../app/controllers/api');\nconst auth = require('../app/controll... | javascript | chosen |
[
{
"from": "system",
"value": "Add route for login page\n"
},
{
"from": "human",
"value": "import React, { Component } from 'react';\nimport { Router, Route, Switch } from 'react-router-dom';\nimport { hot } from 'react-hot-loader';\n\nimport SignUpPage from './SignUp/SignUpPage';\n\nclass App ex... | javascript | chosen |
[
{
"from": "system",
"value": "Change onAnimating/ed to individual ref\n\nAlso switch zIndex to elevation on android because there’s nasty bug,\nhttps://github.com/gitim/react-native-sortable-list/issues/2. Only\nshowed up when android back through shared elements to shared elements\n(changed grid to go to g... | javascript | chosen |
[
{
"from": "system",
"value": "Add a ctx.save and a ctx.restore\n\njohn\n"
},
{
"from": "human",
"value": "/**\n\t_enyo.canvas.line_ is a canvas control that draws a line fitting\n\tthe parameters specified in\tthe _bounds_ property.\n*/\nenyo.kind({\n\tname: \"enyo.canvas.line\",\n\tkind: enyo.c... | javascript | chosen |
[
{
"from": "system",
"value": "Switch to ReactNative Linking API\n\nBased on https://docs.expo.io/versions/latest/guides/linking.html"
},
{
"from": "human",
"value": "/**\n * A Link element for React Native\n *\n * Currently links to http:// URLs\n *\n */\nvar React = require('react-native');\n\n... | javascript | chosen |
[
{
"from": "system",
"value": "Create chain agent in Tracker\n"
},
{
"from": "human",
"value": "/**\n * @file Ethereum taint tracker.\n * @module tracker/tracker\n */\n\n'use strict'\n\n// Imports\nconst Cache = require('../cache/cache')\n\n/**\n * Private members store.\n * @private\n */\nconst ... | javascript | chosen |
[
{
"from": "system",
"value": "Check how Travis handles stderr output\n"
},
{
"from": "human",
"value": "#!/usr/bin/env node\nvar fold = require('./index.js'),\n\tret;\n\nret = [\n\tfold.start('foo'),\n\t'bar',\n\t'next line',\n\t'next line',\n\tfold.start('bar'),\n\t'next line',\n\t'next line',\... | javascript | chosen |
[
{
"from": "system",
"value": "Remove the warning for using Flowtype in Windows ✅\n"
},
{
"from": "human",
"value": "import { execFile } from 'child_process'\nimport flow from 'flow-bin'\nimport { logError, logWarning, log } from '../util/log'\n\nconst errorCodes = {\n TYPECHECK_ERROR: 2\n}\n\ne... | javascript | chosen |
[
{
"from": "system",
"value": "Fix log in (normalizr update issue)\n"
},
{
"from": "human",
"value": "/* eslint-disable no-param-reassign */\n/* eslint-disable fp/no-mutation */\n\nimport { schema } from 'normalizr';\nimport moment from 'moment';\nimport { decodeUnicode } from './../utils/base64'... | javascript | chosen |
[
{
"from": "system",
"value": "Enable minification for esbuild in production.\n"
},
{
"from": "human",
"value": "const watch = process.argv.includes(\"--watch\") && {\n\n /**\n * Log when a build is finished or failed.\n *\n * @param {Error|null} error The possible error.\n * @returns {v... | javascript | chosen |
[
{
"from": "system",
"value": "Use composition instead of inheritance for PluginPass\n"
},
{
"from": "human",
"value": "import type Plugin from \"./plugin\";\nimport Store from \"../store\";\nimport traverse from \"comal-traverse\";\nimport File from \"./file\";\n\nexport default class PluginPass... | javascript | chosen |
[
{
"from": "system",
"value": "Modify <button> format to 1 line\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport ClipboardJS from 'clipboard';\nimport 'balloon-css/balloon.css';\n\nexport default class CopyButton extends React.PureComponent {\n constructor(props) {\n supe... | javascript | chosen |
[
{
"from": "system",
"value": "Add airtable in CSP policy\n"
},
{
"from": "human",
"value": "'use strict';\n\nconst { defaultsDeep, merge } = require('lodash/fp');\nconst helmet = require('koa-helmet');\n\nconst defaults = {\n crossOriginEmbedderPolicy: false,\n crossOriginOpenerPolicy: false,\... | javascript | chosen |
[
{
"from": "system",
"value": "Fix bug by calling hasSymbolSupport function\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/de... | javascript | chosen |
[
{
"from": "system",
"value": "Rename javascript function to bv_form and fix bugs\n"
},
{
"from": "human",
"value": "/***\n * BootstrapValidatorRails\n *\n * @author Jack A. Huang\n * @url http://github.com/huynhquancam/bootstrap_validator_rails/\n */\nvar bootstrap_validation_forms = function(fo... | javascript | chosen |
[
{
"from": "system",
"value": "Fix name of connect method\n"
},
{
"from": "human",
"value": "/*jslint browserify: true */\n\"use strict\";\n\nvar connect = require('../bower_components/dolphin-js/dist/dolphin.js').connect2;\nvar setupCreateBehavior = require('./behavior.js').setupCreateBehavior;\... | javascript | chosen |
[
{
"from": "system",
"value": "Use two files for babel caching.\n\nThis avoids weirdness with two processes writing to the same file.\n"
},
{
"from": "human",
"value": "require('babel-register')\nrequire('babel-polyfill')\n\n// $ <executable> <script> <moduleName> ...\nconst modName = process.arg... | javascript | chosen |
[
{
"from": "system",
"value": "GF-4248: Adjust main menu wide template.\n\nTo be used in Activity one panel up sample, some code should be\nmodified.\n\nEnyo-DCO-1.1-Signed-off-by: David Um <david.um@lge.com>\n"
},
{
"from": "human",
"value": "enyo.kind({\n name: \"moon.sample.video.MainMenuWi... | javascript | chosen |
[
{
"from": "system",
"value": "Fix error on fibonacci generator\n\nStill you miss 0, 1 or 1 at the beginning but it's easy to add it"
},
{
"from": "human",
"value": "function* fibonacci () {\n var older = 1;\n var old = 0;\n\n while (true) {\n yield old + older;\n older = old;\n old +... | javascript | chosen |
[
{
"from": "system",
"value": "Add jsdoc validation to eslint config.\n\nAdd as a warning (documentation updates will be done in a followup).\n"
},
{
"from": "human",
"value": "module.exports = {\n root: true,\n extends: ['eslint:recommended', 'prettier'],\n plugins: ['prettier'],\n parserOpt... | javascript | chosen |
[
{
"from": "system",
"value": "Disable \"indent\" rule in ESLint, let Prettify do it"
},
{
"from": "human",
"value": "module.exports = {\n env: {\n browser: true,\n es6: true,\n jest: true,\n node: true,\n webextensions: true,\n },\n extends: [\n 'eslint:recommended',\n 'p... | javascript | chosen |
[
{
"from": "system",
"value": "Make it work with proper import again.\n\n"
},
{
"from": "human",
"value": "/* eslint-disable no-undef */\nimport { fork, call, select } from 'redux-saga/effects';\nimport worona from 'worona-deps';\nimport * as deps from '../deps';\n\nfunction* redirectHome() {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Revert \"Attempt to get fontawesome working on Heroku\"\n\nThis reverts commit 00df04abd6c8b7bc87350cf2c25ba54a911a1609.\n"
},
{
"from": "human",
"value": "// This file is automatically compiled by Webpack, along with any other files\n// present in this directory. Y... | javascript | chosen |
[
{
"from": "system",
"value": "Use encodeURIComponent() on selected text variable; move result url to variable.\n"
},
{
"from": "human",
"value": "var { Hotkey } = require(\"sdk/hotkeys\");\nvar { ActionButton } = require(\"sdk/ui/button/action\");\nvar Request = require(\"sdk/request\").Request;... | javascript | chosen |
[
{
"from": "system",
"value": "Add functions for retrieving the view center and position\n"
},
{
"from": "human",
"value": "function Annotation(id, viewPos, dataPos, dataPosProj) {\n this.id = id;\n\n this.minX = viewPos[0];\n this.maxX = viewPos[1];\n this.minY = viewPos[2];\n this.maxY = v... | javascript | chosen |
[
{
"from": "system",
"value": "Add method to create a new key\n"
},
{
"from": "human",
"value": "var _ = require('lodash');\n\nvar model = require('./model');\nvar pagination = require('./pagination');\nvar Key = require('./key');\n\nvar Book = model.create(function(bookId) {\n this.id = bookI... | javascript | chosen |
[
{
"from": "system",
"value": "Fix parent class for admin layout js\n"
},
{
"from": "human",
"value": "/**\n * @class Admin_Layout_Default\n * @extends Backbone.View\n */\nvar Admin_Layout_Default = Backbone.View.extend({\n\n\t/** @type String */\n\t_class: 'Admin_Layout_Default'\n});\n"
},
{... | javascript | chosen |
[
{
"from": "system",
"value": "Add check for if request was for profile data\n"
},
{
"from": "human",
"value": "angular\n .module('confRegistrationWebApp')\n .factory(\n 'unauthorizedInterceptor',\n function ($window, $q, $cookies, envService, $location, loginDialog) {\n return {\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Convert third pillar setup to react-intl\n"
},
{
"from": "human",
"value": "import React from 'react';\nimport Types from 'prop-types';\nimport { Link, Redirect } from 'react-router-dom';\nimport { connect } from 'react-redux';\nimport { Message } from 'retranslate'... | javascript | chosen |
[
{
"from": "system",
"value": "Fix bug that prevents default admin user from seeing companies list\n\n"
},
{
"from": "human",
"value": "/**\n * BusinessUnit publications\n */\n\nCore.publish(\"BusinessUnits\", function () {\n let user = this.userId;\n\n // if (Core.hasPayrollAccess(user) ||... | javascript | chosen |
[
{
"from": "system",
"value": "Enforce 20s timeout for all unit tests.\n"
},
{
"from": "human",
"value": "jQuery.noConflict(); // Allow the test to run with other libs or jQuery's.\n\n// jQuery-specific QUnit.reset\n(function() {\n\tvar reset = QUnit.reset,\n\t\tajaxSettings = jQuery.ajaxSettings... | javascript | chosen |
[
{
"from": "system",
"value": "Fix check for presence of elements\n"
},
{
"from": "human",
"value": "protractor.expect = {\n challengeSolved: function (context) {\n describe('(shared)', () => {\n beforeEach(() => {\n browser.get('/#/score-board')\n })\n\n it(\"challenge ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix order of rendering for unit test\n"
},
{
"from": "human",
"value": "import Ember from 'ember';\nimport { moduleForComponent, test } from 'ember-qunit';\n\nmoduleForComponent( 'sl-calendar-year', 'Unit - component: sl-calendar-year' );\n\ntest( 'Default state is ... | javascript | chosen |
[
{
"from": "system",
"value": "Add delimiter to result value\n"
},
{
"from": "human",
"value": "$(document).ready(function() {\n\n $('.search').on('click', function() {\n $.post( '/grant_gateway/search', $('#search-form').serialize(), function(data) {\n var total_value = 0;\n $('.re... | javascript | chosen |
[
{
"from": "system",
"value": "Revert \"Update hacking period start\"\n"
},
{
"from": "human",
"value": "const moment = require('moment');\n\nfunction getHackathonStartDate() {\n return moment('2018-01-20');\n}\n\nfunction getHackathonEndDate() {\n return getHackathonStartDate().add(1, 'day');\... | javascript | chosen |
[
{
"from": "system",
"value": "Rename method and remove debugging code"
},
{
"from": "human",
"value": "var App = angular.module('Ohtu-Hatut', []);\n\nApp.controller('ReferenceController', function ($scope, $http) {\n\n getReferences();\n\n $scope.confirmDeletion = function (referenceId) {\... | javascript | chosen |
[
{
"from": "system",
"value": "Update add braces to control statement\n"
},
{
"from": "human",
"value": "import * as React from \"react\";\nimport {BuildSnapshot} from \"./BuildSnapshot\";\nimport {Wrapper} from \"./Wrapper\";\n\n/**\n * Container Component for BuildSnapshots.\n * \n * @param {*}... | javascript | chosen |
[
{
"from": "system",
"value": "Remove filename from bike schema\n"
},
{
"from": "human",
"value": "exports.up = function up (knex, Promise) {\n return knex.schema\n .createTable('bikes', t => {\n t.uuid('bikeshed_id').references('bikesheds.id').index()\n t.text('field')\n t.text('filen... | javascript | chosen |
[
{
"from": "system",
"value": "Use `.querySelector()` instead of `.getElementById()`\n"
},
{
"from": "human",
"value": "function decodeFragmentValue(hash) {\n try {\n return decodeURIComponent(hash.slice(1));\n } catch {\n return '';\n }\n}\n\nfunction findElementByFragmentName(document,... | javascript | chosen |
[
{
"from": "system",
"value": "Make sure to preload facility config on the user profile page.\n"
},
{
"from": "human",
"value": "import store from 'kolibri.coreVue.vuex.store';\nimport redirectBrowser from 'kolibri.utils.redirectBrowser';\nimport ProfilePage from './views/ProfilePage';\nimport Pr... | javascript | chosen |
[
{
"from": "system",
"value": "Use willMount/willReceiveProps in history actions\n"
},
{
"from": "human",
"value": "import React, { PropTypes } from 'react'\nimport {\n historyContext as historyContextType\n} from './PropTypes'\n\nclass HistoryAction extends React.Component {\n static contextTy... | javascript | chosen |
[
{
"from": "system",
"value": "Use 'React.Children.forEach()' to handle where children might not be array\n"
},
{
"from": "human",
"value": "import SelectOption from '../SelectOption';\n\n/**\n * Convert children of `<SelectOptions>` components to array of options.\n *\n * @param {array} children... | javascript | chosen |
[
{
"from": "system",
"value": "fix(react-wildcat-handoff): Add data-react-available hook on callback\n"
},
{
"from": "human",
"value": "\"use strict\";\n\nvar ReactDOM = require(\"react-dom\");\nvar Router = require(\"react-router\");\nvar clientContext = require(\"./clientContext.js\");\n\nvar m... | javascript | chosen |
[
{
"from": "system",
"value": "Add fetch methods for API cals to themoviedb for popular, upcoming, latest\n"
},
{
"from": "human",
"value": "angular.module('zeus.landing', [])\n .controller('LandingController', function() {\n\n\n });"
},
{
"from": "gpt",
"value": "angular.module('ze... | javascript | chosen |
[
{
"from": "system",
"value": "Add 'value' attribute set to 'branch.name' on button element\n"
},
{
"from": "human",
"value": "import React, {PropTypes} from 'react';\n\nconst BranchesListRow = ({repoId, branch, onSelect}) => {\n return (\n <button type=\"button\" className=\"list-group-item\... | javascript | chosen |
[
{
"from": "system",
"value": "[zmarkdown] Allow using details for custom-blocks\n"
},
{
"from": "human",
"value": "const gh = require('hast-util-sanitize/lib/github')\nconst katex = require('./katex')\nconst merge = require('deepmerge')\n\nmodule.exports = merge.all([gh, katex, {\n tagNames:... | javascript | chosen |
[
{
"from": "system",
"value": "Remove unnecessary assertion for `Ember.inspect`\n\nThe assertion for `Ember.inspect` with error object depends on\n`Error#toString`.\n\nIt returns the value that provided by each environments.\n"
},
{
"from": "human",
"value": "module(\"Ember.inspect\");\n\nvar ins... | javascript | chosen |
[
{
"from": "system",
"value": "Correct default handling of collection key\n"
},
{
"from": "human",
"value": "import stableStringify from 'json-stable-stringify';\n\nfunction defaultGetId(item) {\n return item.id;\n}\n\nfunction defaultCollectionKey(options) {\n if (!options) {\n return '';\n... | javascript | chosen |
[
{
"from": "system",
"value": "Stop mysql auto-inserting 0 into owner_id field\n"
},
{
"from": "human",
"value": "var common = require('../common');\nvar assert = require('assert');\n\ncommon.createConnection(function (err, db) {\n var testRequired = function(required, done) {\n var P... | javascript | chosen |
[
{
"from": "system",
"value": "Use defined constant for DOCKER\n"
},
{
"from": "human",
"value": "import {JSONReducer as env} from './serviceForm/EnvironmentVariables';\nimport {JSONReducer as labels} from './serviceForm/Labels';\nimport {JSONReducer as volumes} from './serviceForm/Volumes';\nimp... | javascript | chosen |
[
{
"from": "system",
"value": "Remove the fallback, which was in the wrong place."
},
{
"from": "human",
"value": "import http from 'http';\nimport url from 'url';\nimport fs from 'fs';\n\nexport const loadViaNode = (fileUrl, onLoaded) => {\n let data = '';\n let options = url.parse(fileUrl);\n... | javascript | chosen |
[
{
"from": "system",
"value": "Add new property to factory\n"
},
{
"from": "human",
"value": "import { Factory, faker } from 'ember-cli-mirage';\n\nexport default Factory.extend({\n name: '',\n\n autoRevert: () => Math.random() > 0.5,\n promoted: () => Math.random() > 0.5,\n\n desiredTotal: f... | javascript | chosen |
[
{
"from": "system",
"value": "Enable transit to show page, when resource node is clicked.\n"
},
{
"from": "human",
"value": "if ($.jstree) {\n $(\".bx-resources\").each(function() {\n $(this).jstree({\n \"plugins\" : [\"html_data\", \"cookies\", \"themes\"]\n });\n });\n}\n\n$(\"#fo... | javascript | chosen |
[
{
"from": "system",
"value": "Configure raw file loader for reading texts from files\n"
},
{
"from": "human",
"value": "/* eslint import/no-extraneous-dependencies: [\"error\", {\"devDependencies\": true}] */\nimport webpack from 'webpack';\n\nexport default {\n context: __dirname,\n entry: '.... | javascript | chosen |
[
{
"from": "system",
"value": "Use $window service instead of global window object (best practice)\n"
},
{
"from": "human",
"value": "'use strict';\n\n/**\n * Desktop notifications\n * see http://caniuse.com/#search=notifications\n *\n * If the browser does not support notifications, the message ... | javascript | chosen |
[
{
"from": "system",
"value": "Allow submit with enter on all modals\n"
},
{
"from": "human",
"value": "(function($) {\n \n\t$( '.modal.fade' ).on( 'keypress', function( e ) {\n\t if( e.keyCode === 13 ) {\n\t e.preventDefault();\n\t $( this ).find('.btn-accept-modal').click();\... | javascript | chosen |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.