conversations listlengths 2 3 | source stringclasses 1
value | stack stringclasses 1
value |
|---|---|---|
[
{
"from": "system",
"value": "Add some code to initialize all of the models recursively.\n"
},
{
"from": "human",
"value": "var App = Em.Application.create();\n\n// Create the data store.\n//\nApp.store = DS.Store.create();\n"
},
{
"from": "gpt",
"value": "var App = Ember.Application... | javascript | chosen |
[
{
"from": "system",
"value": "Add console statement for testing.\n"
},
{
"from": "human",
"value": "var Backbone = require('backbone');\nvar $ = require(\"jquery\");\nvar Router = require('./router');\nvar PlayerView = require('./views/playerView');\nvar NavView = require('./views/navView');\n\n... | javascript | chosen |
[
{
"from": "system",
"value": "Add more types to the localisation\n\nSigned-off-by: soupette <0a59f0508aa203bc732745954131d022d9f538a9@gmail.com>\n"
},
{
"from": "human",
"value": "const LOCALIZED_FIELDS = [\n 'text',\n 'string',\n 'richtext',\n 'email',\n 'password',\n 'media',\n 'number'... | javascript | chosen |
[
{
"from": "system",
"value": "Test updated props passed through to a TextRegion"
},
{
"from": "human",
"value": "import { expect, json, stub } from '../../spec_helper'\nimport { parsePost } from '../../../src/components/parsers/PostParser'\n\ndescribe('PostParser', () => {\n it('#render', () =>... | javascript | chosen |
[
{
"from": "system",
"value": "Make IE11 consumers life (a little bit) easier\n\nSimilarly to #870, provides a pure IE11 compliant includes-like for users that don't polyfill."
},
{
"from": "human",
"value": "/* eslint-disable no-console */\nimport configuration from './configuration'\n\nconst lo... | javascript | chosen |
[
{
"from": "system",
"value": "Change default loadMore and limit configuration\n"
},
{
"from": "human",
"value": "Comments.ui = (function () {\n Avatar.options = {\n defaultImageUrl: 'http://s3.amazonaws.com/37assets/svn/765-default-avatar.png'\n };\n\n Tracker.autorun(function () {\n va... | javascript | chosen |
[
{
"from": "system",
"value": "Improve code structure in preparation for implementation of localization for projects page.\n"
},
{
"from": "human",
"value": "'use strict';\n\nangular.module('arachne.controllers')\n\n\n/**\n * @author: Daniel M. de Oliveira\n * @author: Sebastian Cuy\n */\n.contro... | javascript | chosen |
[
{
"from": "system",
"value": "Modify arguments of post function\n"
},
{
"from": "human",
"value": "michishiki.api = {};\nmichishiki.api.uri = 'http://amateras.wsd.kutc.kansai-u.ac.jp/~otsuka/michishiki_api_server/';\n\nmichishiki.api.getPost = function(options) {\n var dfd = $.Deferred();\n\n... | javascript | chosen |
[
{
"from": "system",
"value": "Change sequelize to use new logger\n"
},
{
"from": "human",
"value": "// Sequelize Initialization\nvar fs = require('fs');\nvar path = require('path');\nvar Sequelize = require('sequelize');\nvar lodash = require('lodash');\nvar config = require('.... | javascript | chosen |
[
{
"from": "system",
"value": "Use experimental object observers for mocking. only works in chromium for now.\n"
},
{
"from": "human",
"value": "// ==UserScript==\n// @name Kill nrcQ restrictions\n// @namespace http://use.i.E.your.homepage/\n// @version 0.1\n// @description When browsi... | javascript | chosen |
[
{
"from": "system",
"value": "Clarify comments on module order\n"
},
{
"from": "human",
"value": "import a11y from './a11y';\nimport keys from './keys';\nimport location from './location';\nimport next from './next';\nimport progress from './progress';\nimport scale from './scale';\nimport timer... | javascript | chosen |
[
{
"from": "system",
"value": "Add fallback for unknown commands and help on storybook\n"
},
{
"from": "human",
"value": "import program from 'commander';\nimport pkg from '../package.json';\nimport initiate from '../lib/initiate';\n\nprogram\n .command('init')\n .description('Initialize Storyb... | javascript | chosen |
[
{
"from": "system",
"value": "Fix CSSO compressor output due to package upgrade\n"
},
{
"from": "human",
"value": "/*!\n * node-minify\n * Copyright(c) 2011-2016 Rodolphe Stoclin\n * MIT Licensed\n */\n\n'use strict';\n\n/**\n * Module dependencies.\n */\n\nvar Promise = require('bluebird');\nva... | javascript | chosen |
[
{
"from": "system",
"value": "Set the config object in Reactive Map\n"
},
{
"from": "human",
"value": "import { default as React, Component } from 'react';\nimport { render } from 'react-dom';\nvar helper = require('./helper.js');\n\nexport class ReactiveMap extends Component {\n\n constructor(... | javascript | chosen |
[
{
"from": "system",
"value": "Add collection state, fix errors\n"
},
{
"from": "human",
"value": "(function () {\n function config($stateProvider, $locationProvider) {\n $locationProvider\n .html5Mode({\n enabled: true,\n requireBase: false\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Allow signout in `forceUpgrade` state\n"
},
{
"from": "human",
"value": "import Route from '@ember/routing/route';\nimport {inject as service} from '@ember/service';\n\nRoute.reopen({\n config: service(),\n billing: service(),\n router: service(),\n\n ac... | javascript | chosen |
[
{
"from": "system",
"value": "Add a checker method for the AST of a page\n"
},
{
"from": "human",
"value": "/*\n * Validator for AST nodes\n * @lastmodifiedBy ChengFuLin(chengfulin0806@gmail.com)\n * @lastmodifiedDate 2015-08-03\n */\nfunction ASTValidator() {\n}\n\n/**\n * Check for the node is... | javascript | chosen |
[
{
"from": "system",
"value": "Send full stack trace information on promise rejection\n"
},
{
"from": "human",
"value": "import Ember from 'ember';\nimport { getContext } from 'ember-test-helpers';\n\nfunction resetViews() {\n Ember.View.views = {};\n}\n\nexport default function test(testName, c... | javascript | chosen |
[
{
"from": "system",
"value": "Disable source switcher during walkthrough\n\nCloses #4401 -- fixed as proposed in the issue's comments"
},
{
"from": "human",
"value": "import {\n event as d3_event,\n select as d3_select\n} from 'd3-selection';\n\nimport { t } from '../util/locale';\nimport ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix test for visiting admin page\n"
},
{
"from": "human",
"value": "test('User visits the admin page.', function() {\n visit('/');\n andThen(function() {\n // List of posts\n equal(find('.posts-list .post').length, 2, 'The index page should have 2 posts.');\... | javascript | chosen |
[
{
"from": "system",
"value": "Add a simple assertion for the existence of Backbone\n"
},
{
"from": "human",
"value": "// Ractive-Backbone tests\n// ======================\n//\n// This loads in the render.json sample file and checks that each compiled\n// template, in combination with the sample ... | javascript | chosen |
[
{
"from": "system",
"value": "Fix typo in identifier type code.\n"
},
{
"from": "human",
"value": "const data = [\n { id: 'isbn', name: 'ISBN' },\n { id: 'issn', name: 'ISSN' },\n { id: '0003', name: 'Standard Technical Report number' },\n { id: '0004'... | javascript | chosen |
[
{
"from": "system",
"value": "Fix for alert box error\n"
},
{
"from": "human",
"value": "\nmodule.exports = new function() {\n\n var webdriver = require(\"selenium-webdriver\");\n\n webdriver.WebDriver.prototype.waitJqueryReady = function() {\n var self = this;\n\n return self.flow_.exec... | javascript | chosen |
[
{
"from": "system",
"value": "Rework of test file due to Protractor error\n"
},
{
"from": "human",
"value": "describe('Valencia-Tech Repair Database website', function() {\n\n beforeEach(function () {\n browser.get('http://localhost:3000');\n });\n\n /*-----------------------------... | javascript | chosen |
[
{
"from": "system",
"value": "Add nano & proxy access to couchdb\n\nSPA served off '/' route; '/api/*' routes proxied to couchdb.\n"
},
{
"from": "human",
"value": "const express = require('express');\nconst app = express();\n\nconst port = process.env.PORT || 8080;\n\napp.get('/', (req, res) =>... | javascript | chosen |
[
{
"from": "system",
"value": "Add new-action button to toggle default_block for messages\n"
},
{
"from": "human",
"value": "$(document).on('page:load', init_default_data_block);\n$(document).ready(init_default_data_block);\n\nfunction init_default_data_block() {\n $('.default_data_block .titl... | javascript | chosen |
[
{
"from": "system",
"value": "Use client locale for date format\n"
},
{
"from": "human",
"value": "import moment from 'moment';\n\nTemplate.dateCell.helpers({\n 'formattedDate': function () {\n // Load the Finnish locale\n moment.locale('fi');\n\n // Create resident latest activity var... | javascript | chosen |
[
{
"from": "system",
"value": "Delete ID from template on drop\n"
},
{
"from": "human",
"value": "import Ember from 'ember';\nimport RSVP from 'rsvp';\nimport WithDropzone from 'canvas-web/mixins/with-dropzone';\nimport layout from './template';\nimport styles from './styles';\n\nconst { inject, ... | javascript | chosen |
[
{
"from": "system",
"value": "Add get profile feature to backend\n"
},
{
"from": "human",
"value": "import express from 'express';\n\nimport * as User from '../../controllers/users';\nimport * as Recipe from '../../controllers/recipes';\nimport * as Favorite from '../../controllers/favorites';\n... | javascript | chosen |
[
{
"from": "system",
"value": "Improve precision of related post s\n"
},
{
"from": "human",
"value": "var _ = require('lodash');\n\nfunction parseId(postData, type) {\n type = type || 'tags';\n return postData[type].data.map(function(t) { return t._id; });\n}\n\nfunction getSimilarityScore(arrA... | javascript | chosen |
[
{
"from": "system",
"value": "Check if the given parameter is an array.\n"
},
{
"from": "human",
"value": "module = module.exports = function (arr) {\n var len = arr.length,\n random,\n temp;\n\n while (len) {\n random = Math.floor(Math.random() * len);\n len -=... | javascript | chosen |
[
{
"from": "system",
"value": "Fix returned promise upon errors\n\nFixes #5.\n"
},
{
"from": "human",
"value": "'use strict';\nconst execa = require('execa');\nconst getos = require('getos');\nconst pify = require('pify');\n\nmodule.exports = () => {\n\tif (process.platform !== 'linux') {\n\t\tre... | javascript | chosen |
[
{
"from": "system",
"value": "Update final catch error message for the owner\n\nLet the owner know that an unhandled exeception bubbled all the way to the top and will shut down Nix"
},
{
"from": "human",
"value": "'use strict';\nconst fs = require('fs');\nconst Discord = require('discord.js');\... | javascript | chosen |
[
{
"from": "system",
"value": "Make sure content of po files is read in utf8\n"
},
{
"from": "human",
"value": "\n\nvar through = require('through2'),\n gutil = require('gulp-util'),\n po = require('node-po'),\n PluginError = gutil.PluginError;\n\nmodule.exports = function () {\n\n fu... | javascript | chosen |
[
{
"from": "system",
"value": "Allow multiple tensorflow instances in js\n"
},
{
"from": "human",
"value": "\nimport { NativeModules } from 'react-native';\n\nconst { RNTensorflow } = NativeModules;\n\nclass Tensorflow {\n\n initWithModel(modelFileName) {\n RNTensorflow.initTensorflow(modelFi... | javascript | chosen |
[
{
"from": "system",
"value": "Check if `_requireBuildPackages()` exists before calling it\n\nThis is needed to make the project compatible with Ember CLI 3.7+\n"
},
{
"from": "human",
"value": "/* eslint-env node */\n'use strict';\n\nvar Append = require('./lib/broccoli-append');\nvar path = req... | javascript | chosen |
[
{
"from": "system",
"value": "Fix typo in require statement\n"
},
{
"from": "human",
"value": "'use strict';\nvar postcssCached = require('postcss-cached');\nvar through = require('through2');\nvar applySourceMap = require('vinyl-sourcemans-apply');\nvar gulpUtil = require('gulp-util');\n\nmodul... | javascript | chosen |
[
{
"from": "system",
"value": "Make sure serialized content don't get unserialized\n"
},
{
"from": "human",
"value": "var cookie = require('cookie');\n\nvar _cookies = cookie.parse((typeof document !== 'undefined') ? document.cookie : '');\n\nfor (var key in _cookies) {\n try {\n _cookies[key... | javascript | chosen |
[
{
"from": "system",
"value": "Remove another constant and shorten require path\n"
},
{
"from": "human",
"value": "const redis = require('./redis');\nconst config = require('../config/index.js');\n\nconst getRequest = async (requestId) => {\n // Set TTL for request\n redis.expire(`requests:${re... | javascript | chosen |
[
{
"from": "system",
"value": "Rewrite OL+ legend to be non-drupaly.\n"
},
{
"from": "human",
"value": "var OpenLayersPlusLegend = {};\n\nOpenLayersPlusLegend = {};\n\nOpenLayersPlusLegend.attach = function(context) {\n var data = $(context).data('openlayers');\n if (data && data.map.behaviors.... | javascript | chosen |
[
{
"from": "system",
"value": "Add all javascript sources to server-watcher.\n"
},
{
"from": "human",
"value": "module.exports = function(grunt) {\n \"use strict\";\n \n // Project configuration.\n grunt.initConfig({\n pkg: '<json:package.json>',\n \n test: {\n files: ['test/**/... | javascript | chosen |
[
{
"from": "system",
"value": "Update Reschedule and Clear functions, create Destroy function."
},
{
"from": "human",
"value": "'use strict'\n\nfunction ReInterval (callback, interval, args) {\n var self = this;\n\n this._callback = callback;\n this._args = args;\n\n this._interval = setInter... | javascript | chosen |
[
{
"from": "system",
"value": "Include roboto font in app head - DW\n"
},
{
"from": "human",
"value": "import React from 'react'\nimport Document, { Head, Main, NextScript } from 'next/document'\nimport { ServerStyleSheet } from 'styled-components'\n\nexport default class MyDocument extends Docum... | javascript | chosen |
[
{
"from": "system",
"value": "Add console logging to script\n"
},
{
"from": "human",
"value": "var _ = require('underscore');\nvar AWS = require('aws-sdk');\nvar moment = require('moment');\nvar path = require('path');\nvar async = require('async');\n\nvar Uploader = require('s3-streaming-upload... | javascript | chosen |
[
{
"from": "system",
"value": "Make the regexp a bit more efficient and correct\n"
},
{
"from": "human",
"value": "var stringsAndFlowComments = /(`(?:.|\\s)*?`|'(?:.|\\s)*?'|`(?:.|\\s)*?`|\"(?:.|\\s)*?\"|\\/\\*.*?(?::{1,2}|flow-include).*?(?:.|\\s)*?\\*\\/)/;\n\nfunction removeComments(code){\n\t... | javascript | chosen |
[
{
"from": "system",
"value": "Move the array handling logic into `add`\n"
},
{
"from": "human",
"value": "'use strict'\n\nvar through = require('through2')\n\nmodule.exports = function (/*streams...*/) {\n var firstTick = true;\n var sources = []\n var output = through.obj()\n var args = ar... | javascript | chosen |
[
{
"from": "system",
"value": "Switch .markdown extension to .html after conversion"
},
{
"from": "human",
"value": "var Pagemaki = require(\"pagemaki\");\nvar Buffer = require(\"buffer\").Buffer;\nvar through = require(\"through\");\n\n/**\n * Returns a file handling function that can \n * be pi... | javascript | chosen |
[
{
"from": "system",
"value": "Update: Reduce object creation for end-of-stream options\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar domain = require('domain');\n\nvar eos = require('end-of-stream');\nvar tick = require('next-tick');\nvar once = require('once');\nvar exhaust = require(... | javascript | chosen |
[
{
"from": "system",
"value": "Update to use new module pinyin-api\n"
},
{
"from": "human",
"value": "'use strict'\n\nrequire(\"babel-core/register\")\nrequire(\"babel-polyfill\")\n\nconst convert = require('pinyin-convert')\nconst split = require('pinyin-split')\n\nconst execute = () => {\n\tcon... | javascript | chosen |
[
{
"from": "system",
"value": "Increase hook timeout to 3 min\n"
},
{
"from": "human",
"value": "module.exports = {\n\n port: 1337,\n serverUrl: process.env.SERVER_URL || 'http://127.0.0.1:1337'\n\n};\n"
},
{
"from": "gpt",
"value": "module.exports = {\n\n port: 1337,\n serverUrl:... | javascript | chosen |
[
{
"from": "system",
"value": "Add 0x to blockhash generation in getBlock for fakeBlockchain for consistent hashes\n"
},
{
"from": "human",
"value": "const Buffer = require('safe-buffer').Buffer\nconst utils = require('ethereumjs-util')\n\nmodule.exports = {\n getBlock: function (blockTag, cb) {... | javascript | chosen |
[
{
"from": "system",
"value": "Use our $A.util classes for browser compat\n"
},
{
"from": "human",
"value": "/*\n * Copyright (C) 2013 salesforce.com, inc.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License... | javascript | chosen |
[
{
"from": "system",
"value": "Insert Script Tag at Foot of the `<head>` Tag\n\nEnsures we're less likely to inflict damage to people's performance due\nto tag ordering.\n"
},
{
"from": "human",
"value": "/* jshint node: true */\n'use strict';\n\nmodule.exports = {\n name: 'ember-cli-trackjs',\n... | javascript | chosen |
[
{
"from": "system",
"value": "Simplify readable concat w/ Buffer.isBuffer and [].map\n"
},
{
"from": "human",
"value": "'use strict'\n\nvar toArray = require('stream-to-array')\nvar Promise = require('bluebird')\n\nmodule.exports = streamToPromise\n\nfunction streamToPromise (stream) {\n var pr... | javascript | chosen |
[
{
"from": "system",
"value": "Throw an error if dropping the collections took more than 2s\n"
},
{
"from": "human",
"value": "/**\n * External dependencies.\n */\n\nvar mongoose = require('mongoose');\n\n/**\n * Drop all known mongoose collections before\n * each test.\n *\n * @param {Object} hy... | javascript | chosen |
[
{
"from": "system",
"value": "Add delim support and trim\n"
},
{
"from": "human",
"value": "var delim = \"---\\n\";\nvar assign = require('object-assign');\n\nmodule.exports = function(converter) {\n\n return function (pages, done) {\n\n try {\n\n pages.forEach(function(page... | javascript | chosen |
[
{
"from": "system",
"value": "Fix Chrome tests on Travis\n"
},
{
"from": "human",
"value": "/* eslint-env node */\n\nmodule.exports = {\n test_page: 'tests/index.html?hidepassed',\n disable_watching: true,\n launch_in_ci: [\n 'Chrome'\n ],\n launch_in_dev: [ ],\n browser_args: {\n Ch... | javascript | chosen |
[
{
"from": "system",
"value": "Use error handlers for 400 page\n"
},
{
"from": "human",
"value": "var express = require('express');\nvar router = express.Router();\n\n\nrouter.get('/search', function(req, res) {\n if (!req.query.hasOwnProperty(\"inp\")) return res.sendStatus(400);\n res.ren... | javascript | chosen |
[
{
"from": "system",
"value": "Remove old commented out code.\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar fs = require( 'fs' );\nvar routes = {};\n\n// load all definitions\nfs.readdirSync( __dirname ).filter( function( file ) {\n // return true IF not a dotfile AND not this file\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Add message parameter to database when creating a post\n"
},
{
"from": "human",
"value": "//exports.list = function (req, res) {\n// res.send({\n// \"lat\": 5.552,\n// \"long\": 2.342,\n// \"message\": \"Bong!\",\n// \"tags\": [\"Lifestyle\", \"... | javascript | chosen |
[
{
"from": "system",
"value": "Add get method with parameters"
},
{
"from": "human",
"value": "(function () {\n 'use strict';\n\n angular\n .module('app')\n .controller('StudentController', StudentController);\n\n function StudentController($scope, $http) {\n var vm... | javascript | chosen |
[
{
"from": "system",
"value": "Remove url commented in google sevice.\n"
},
{
"from": "human",
"value": "\"use strict\";\n\n// http://www.google.com/finance/match?matchtype=matchall&q=msft\n// http://www.google.com/finance/match?&q=?matchtype=matchall&q=msft\n(function () {\n angular\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Use package version for printing"
},
{
"from": "human",
"value": "var PrintDocumentationCommand = function () {\n var handle = function () {\n console.log('Space Kitty - Version 1.0.0');\n console.log('');\n console.log('├── create ─ Create a n... | javascript | chosen |
[
{
"from": "system",
"value": "Update to match new book data JSON format (list not hash)\nAlso fixed the waiting issue after completion\n"
},
{
"from": "human",
"value": "// Load the book metadata into MongoDB from book_metadata.json\n\nvar databaseURI = \"localhost:27017/bldata\";\nvar collectio... | javascript | chosen |
[
{
"from": "system",
"value": "Upgrade request to 2.47.0 from 2.33.0\n\nLooks like it now auto-detects $HTTP_PROXY so we could drop that code\nfrom http-helpers (but not from the faye stuff).\n"
},
{
"from": "human",
"value": "Package.describe({\n summary: \"Wraps the request module from Npm in ... | javascript | chosen |
[
{
"from": "system",
"value": "Use an instance variable for match tracking.\n\nWhen accessing state along context, something is up with setState enqueued updates not dispatching. It might have to do with ReactNoopUpdateQueue being used on the server side, but I'm not 100% sure. For now, this non-idiomatic wo... | javascript | chosen |
[
{
"from": "system",
"value": "Add the Javascript half of the new Geolocation code\n"
},
{
"from": "human",
"value": "var constructGeolocationLink = function constructGeolocationLink($wrapper){\n var geolocationIsSupported = false;\n if (\"geolocation\" in navigator) {\n geolocationI... | javascript | chosen |
[
{
"from": "system",
"value": "Add missing props for copyTemplate\n"
},
{
"from": "human",
"value": "const fountain = require('fountain-generator');\n\nmodule.exports = fountain.Base.extend({\n writing() {\n const name = this.options.name || 'myComponent';\n const titleCase = string => str... | javascript | chosen |
[
{
"from": "system",
"value": "Update Jasmine syntax examples to make them shorter.\n"
},
{
"from": "human",
"value": "describe(\"Gilded Rose\", function() {\n var foo;\n\n // beforeEach(function() {\n // foo = 0;\n // foo += 1;\n // });\n\n // afterEach(function() {\n // foo = 0;\n ... | javascript | chosen |
[
{
"from": "system",
"value": "Allow additional options params in sticky toolbar plugin\n"
},
{
"from": "human",
"value": "define('editor-plugin-sticky-toolbar', [], function () {\n return function(toolbarNode) {\n return function() {\n var toolbarOffsetTop,\n scrolled = false;\... | javascript | chosen |
[
{
"from": "system",
"value": "Adjust prop type defs in navigation-main\n\n"
},
{
"from": "human",
"value": "//@flow\n\nimport React from \"react\";\nimport { Title, Wrapper } from \"./styled-components\";\nimport { MainNav } from \"../../elements/navigation-main\";\nimport { Highlight } from \".... | javascript | chosen |
[
{
"from": "system",
"value": "Add versions to the Blacklist\n"
},
{
"from": "human",
"value": "let ServiceConfig = {\n BLACKLIST: [\n 'uris',\n 'ports',\n 'version',\n 'versionInfo',\n 'deployments',\n 'tasks',\n 'taskStats',\n 'tasksHealthy',\n 'tasksRunning',\n '... | javascript | chosen |
[
{
"from": "system",
"value": "Add root to test heroku"
},
{
"from": "human",
"value": "var express = require('express');\nvar app = express();\n//var mongoose = require('mongoose');\n//var config = require('./config');\n\n//mongoose.connect('mongodb://localhost/my_database');\n\napp.set('port', ... | javascript | chosen |
[
{
"from": "system",
"value": ":sparkles: Add in a debug option that defaults to false\n"
},
{
"from": "human",
"value": "'use strict';\n\nconst path = require('path');\nconst pkg = require(path.resolve('./package.json'));\nconst semver = require('semver');\nconst versions = require('./versions.j... | javascript | chosen |
[
{
"from": "system",
"value": "Remove - from assetMap file name\n"
},
{
"from": "human",
"value": "/* jshint node: true */\n'use strict';\n\nlet fs = require('fs');\n\nmodule.exports = {\n name: 'ember-cli-ifa',\n\n isDevelopingAddon: function() {\n return false;\n },\n\n postBuild: functi... | javascript | chosen |
[
{
"from": "system",
"value": "Fix for environments without process var"
},
{
"from": "human",
"value": "var parser = require('js-yaml')\nvar optionalByteOrderMark = '\\\\ufeff?'\nvar pattern = '^(' +\n optionalByteOrderMark +\n '(= yaml =|---)' +\n '$([\\\\s\\\\S]*?)' +\n '^(?:\\\\2|\\\\.\\\... | javascript | chosen |
[
{
"from": "system",
"value": "Add config object description and example\n"
},
{
"from": "human",
"value": "var config = require('./config');\nvar fetch = require('./fetcher');\nvar notify = require('./notifier');\n\nfunction error(err) {\n console.error(err);\n}\n\nfetch(config.consulateUrls, ... | javascript | chosen |
[
{
"from": "system",
"value": "Use request.defaults() to simplify GitHub API calls\n"
},
{
"from": "human",
"value": "var _ = require('underscore');\nvar async = require('async');\nvar request = require('request');\nvar linters = require('./linters');\n\nvar repoURL = 'https://api.github.com/repo... | javascript | chosen |
[
{
"from": "system",
"value": "Add unhandled promise rejection handler\n"
},
{
"from": "human",
"value": "const Source = require(\"./Ship/PollSource.js\");\nconst Connection = require(\"./Ship/Connection.js\");\nconst MessageRouter = require(\"./Ship/MessageRouter.js\");\nconst CommandSource = re... | javascript | chosen |
[
{
"from": "system",
"value": "Fix command line issue with refactoring.\n"
},
{
"from": "human",
"value": "'use strict';\n\nconst program = require('commander');\nconst dachshund = require('./lib/dachshund');\n\nmodule.exports = {\n underToDash: underToDash,\n dashToUnder: dashToUnder\n};\n\nfu... | javascript | chosen |
[
{
"from": "system",
"value": "Increase max listeners to prevent nodes warn.\n"
},
{
"from": "human",
"value": "'use strict';\n\nvar retry = require('retry');\nvar deepExtend = require('deep-extend');\n\nvar errorCodes = [\n 'EADDRINFO',\n 'ETIMEDOUT',\n 'ECONNRESET'\n];\n\nfunction requ... | javascript | chosen |
[
{
"from": "system",
"value": "Use process.std{out,err}.write instead of console.{log,error}\n"
},
{
"from": "human",
"value": "'use strict';\n\nconst chokidar = require('chokidar');\nconst kexec = require('kexec');\nconst childProcess = require('child_process');\n\nchokidar.watch('yarn.lock').on... | javascript | chosen |
[
{
"from": "system",
"value": "[BUGFIX] Allow ember-c3 to be used as a nested addon\n\nThis changes allow ember-c3 to be used as a nested addon.\n"
},
{
"from": "human",
"value": "/* jshint node: true */\n'use strict';\n\nmodule.exports = {\n name: 'ember-c3',\n included: function(app) {\n t... | javascript | chosen |
[
{
"from": "system",
"value": "Add some more visionary words\n"
},
{
"from": "human",
"value": "'use strict';\n\nmodule.exports = defineRules;\n\nvar visionaryWords = [\n /blue\\s*sk(?:y|ies)/,\n /enlighten(?:ed|ing)?/,\n /green\\s*fields?/,\n /reach(?:ed|ing) out/,\n /visionar(?:y... | javascript | chosen |
[
{
"from": "system",
"value": "Refactor to extract click handler creation\n"
},
{
"from": "human",
"value": "import {slideshow} from \"../framework/slideshow\";\nimport Slide from \"../framework/slide\";\n\nclass HelloWorld extends Slide {\n constructor(config) {\n super(config);\n this.co... | javascript | chosen |
[
{
"from": "system",
"value": "Clean some useless code, also add call to background script\n"
},
{
"from": "human",
"value": "document.addEventListener('DOMContentLoaded', function() {\n var checkPageButton = document.getElementById('checkPage');\n checkPageButton.addEventListener('click', func... | javascript | chosen |
[
{
"from": "system",
"value": "Include error message when logging caught exception\n"
},
{
"from": "human",
"value": "module.exports = {};\n\nfunction calculateMove(game_state) {\n try {\n\n if(gameDecision.wantToBet()) {\n return gameDecision.getBetAmount();\n } else if(gameDecision.... | javascript | chosen |
[
{
"from": "system",
"value": "Remove array wrapper on storage get() key\n"
},
{
"from": "human",
"value": "import {getJSON} from './fetch.js';\n\n// Retrieve the raw user preferences without defaults merged in\nexport function getRawPreferences() {\n return new Promise((resolve) => {\n chrom... | javascript | chosen |
[
{
"from": "system",
"value": "Remove gzip stuff for now.\n"
},
{
"from": "human",
"value": "#!/usr/bin/env node\n\nvar chalk = require('chalk'),\n path = require('path'),\n fs = require('fs-extra'),\n // zlib = require('zlib'),\n browserify = require('browserify');\n\nvar EXAMPLES_DI... | javascript | chosen |
[
{
"from": "system",
"value": "Add link to dashboard in app title\n"
},
{
"from": "human",
"value": "import React, { PropTypes } from 'react';\nimport { connect } from 'react-redux';\nimport MuiThemeProvider from 'material-ui/styles/MuiThemeProvider';\nimport AppBar from 'material-ui/AppBar';\nim... | javascript | chosen |
[
{
"from": "system",
"value": "Put AutoFocus focus holder in a portal.\n\n This prevent it from affecting layouts.\n"
},
{
"from": "human",
"value": "import {compose} from 'compose'\nimport PropTypes from 'prop-types'\nimport React from 'react'\nimport withForwardedRef from 'ref'\n\nclass AutoFoc... | javascript | chosen |
[
{
"from": "system",
"value": "Update protocol metadata v4 to accept nullable arrays\n"
},
{
"from": "human",
"value": "const Encoder = require('../../../encoder')\nconst { Metadata: apiKey } = require('../../apiKeys')\n\n/**\n * Metadata Request (Version: 4) => [topics] allow_auto_topic_creation... | javascript | chosen |
[
{
"from": "system",
"value": "Change getting key method (SAAS-612)\n\nChange key text split by '==' to split by whitespace.\nhttp://localhost:8001/#/keys/add/\n"
},
{
"from": "human",
"value": "(function() {\n angular.module('ncsaas')\n .controller('KeyAddController', ['baseControllerAddClas... | javascript | chosen |
[
{
"from": "system",
"value": "Make sure Enemy has its own private scope\n"
},
{
"from": "human",
"value": "\nfunction Enemy(game, x, y, health) {\n Phaser.Sprite.call(this, game, x, y, 'enemy');\n this.scale.setTo(0.25,0.25);\n this.game = game;\n this.health = health;\n}\n\nEnemy.prototyp... | javascript | chosen |
[
{
"from": "system",
"value": "Clean up code a bit, join to rename file\n"
},
{
"from": "human",
"value": "// Eudeba epub uploader\n$(function() {\n\n uploadForm = $(\"form[name=csv-file-upload]\");\n\n // From http://stackoverflow.com/a/16086380\n // uploadForm.submit( function() {\n... | javascript | chosen |
[
{
"from": "system",
"value": "Make ol.View2D available when exploring olx.MapOptions\n"
},
{
"from": "human",
"value": "goog.provide('ol.IView');\n\ngoog.require('ol.IView2D');\ngoog.require('ol.IView3D');\n\n\n\n/**\n * Interface for views.\n * @interface\n */\nol.IView = function() {\n};\n\n\n... | javascript | chosen |
[
{
"from": "system",
"value": "Fix keycloak sample code to use keycloak instead of google\n"
},
{
"from": "human",
"value": "'use strict';\n\n// const unleash = require('unleash-server');\nconst unleash = require('../lib/server-impl.js');\n\nconst enableGoogleOauth = require('./google-auth-hook')... | javascript | chosen |
[
{
"from": "system",
"value": "Remove ajax call for non-character keys\n"
},
{
"from": "human",
"value": "var timeouts = [];\nfunction updateResults() {\n var query = $(\"#query\").val();\n for (var x=0; x<timeouts.length; x++) {\n clearTimeout(timeouts[x]);\n }\n $.getJSON(\n \"/search... | javascript | chosen |
[
{
"from": "system",
"value": "Fix widget sizes to actually fit a 5x3 grid.\n"
},
{
"from": "human",
"value": "var RCSS = require(\"rcss\");\nvar _ = require(\"underscore\");\n\nvar styleVars = require(\"./style-vars.js\");\n\nvar gridSpacing = 15;\nvar nWide = 5;\nvar baseComponentSize = (styleV... | javascript | chosen |
[
{
"from": "system",
"value": "Define to show microdonation popup now\n"
},
{
"from": "human",
"value": "angular.module(\"proBebe.services\")\n.factory('ObserverMicrodonation', function(storage) {\n\n function Observer() {}\n\n Observer.start = function(state){\n var dateShowPopup = storage.... | javascript | chosen |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.