messages listlengths 2 2 | language stringclasses 8
values | prompt_type stringclasses 2
values | lint_errors int64 0 129 ⌀ | cyclomatic_complexity int64 0 32 ⌀ | license stringclasses 7
values | commit stringlengths 40 40 | repos stringlengths 5 116k | new_file stringlengths 4 220 | status stringclasses 6
values | error stringlengths 26 74 ⌀ | is_valid_syntax bool 2
classes |
|---|---|---|---|---|---|---|---|---|---|---|---|
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/* eslint no-console:0 */\n\n/**\n * Spawns an embedded neovim instance and returns Neovim API\n */\n\nconst cp = require('child_process');\nconst attach = require('../attach');\n// const inspect = require('util').inspect;\n\nmodule.exp... | javascript | edit | 0 | 2 | mit | e53bbb5735497395d1ea4cb5a6c13db69792bd19 | rhysd/node-client,neovim/node-client,neovim/node-client | scripts/nvim.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst _ = require('lodash');\nconst exec = require('shell-utils').exec;\n\nconst android = _.includes(process.argv, '--android');\nconst release = _.includes(process.argv, '--release');\nconst skipBuild = _.includes(process.argv, '--ski... | javascript | edit | 0 | 8 | mit | 4aabc4665ec47172415ea66e2593840a50b08ceb | ceyhuno/react-native-navigation,wix/react-native-navigation,guyca/react-native-navigation,ceyhuno/react-native-navigation,chicojasl/react-native-navigation,wix/react-native-navigation,wix/react-native-navigation,thanhzusu/react-native-navigation,guyca/react-native-navigation,ceyhuno/react-native-navigation,ceyhuno/reac... | scripts/test-e2e.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nangular.module('shoppingList').controller(\n 'ShoppingListController', ['$scope', '$window', function($scope, $window) {\n 'use strict';\n\n var blankItem = {\n name: '',\n category: '',\n quantity: '',\n unit... | javascript | edit | 0 | 2 | apache-2.0 | 54aa153de51b8dffe6fa3c609b5727d843c81219 | eheikes/shopping-list,eheikes/shopping-list | app/ShoppingListController.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nfunction merge(...args) {\n let output = null,\n items = [...args];\n while (items.length > 0) {\n const nextItem = items.shift();\n if (!output) {\n output = Object.assign({}, nextItem);\n }... | javascript | edit | 0 | 8 | mit | 0a302a6a1f5bc93c999d25a3b9fdda9aa09b61ba | perry-mitchell/webdav-client,perry-mitchell/webdav-client | source/merge.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport alertsSvc from './Alerts.js';\nimport auditLogsSvc from './AuditLogs.js';\nimport authSvc from './Authorization.js';\nimport exportSvc from './ExportService.js';\nimport exprUtil from './ExpressionUtil.js... | javascript | edit | 0 | 2 | bsd-3-clause | ecdd9c40790cfde9aa3e723d9cb206f61f8fa9f4 | krishagni/openspecimen,krishagni/openspecimen,krishagni/openspecimen | ui/src/common/services/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar mongoose = require('mongoose'),\n _ = require('cloneextend'),\n adHocModels = {};\n\n\nvar adHocModel = function(collectionName, Schema, options) {\n if (!adHocModels[collectionName]) {\n var options = options || {};... | javascript | edit | 0 | 5 | mit | 6f53b8df0c4b187dc5e487d582abd945353eb230 | Safecast/GeoSense,Safecast/GeoSense,Safecast/GeoSense,Safecast/GeoSense,Safecast/GeoSense | geogoose/util.js | rejected_duplicate | Near-duplicate of sample 74194 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/* @flow */\nimport React, { PureComponent } from 'react';\nimport { StyleSheet, Text, View } from 'react-native';\n\nimport type { Narrow, Stream } from '../types';\nimport StreamIcon from '../streams/StreamIcon';\nimport { isTopicNarr... | javascript | edit | null | null | apache-2.0 | 5d7794078d159157860b76c93f1550be9418731d | vishwesh3/zulip-mobile,vishwesh3/zulip-mobile,vishwesh3/zulip-mobile,vishwesh3/zulip-mobile | src/title/TitleStream.js | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nexports.name = \"echidna.editor-ids\";\n\nexports.check = function (sr, done) {\n var editorIDs = sr.$('dd[data-editor-id]').map(function(index, element) {\n var strId = sr.$(element).attr('data-editor-id');\n... | javascript | edit | 0 | 2 | mit | 9c9365a8dbefe86a2275311b6c54a552c9640816 | w3c/specberus,dontcallmedom/specberus,w3c/specberus,w3c/specberus,dontcallmedom/specberus | lib/rules/echidna/editor-ids.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/* eslint-env browser */\nimport {findSingleNode, getFindDOMNode} from './helpers';\n\nlet findDOMNode = findDOMNode || (global && global.findDOMNode);\n\nfunction haveComponentWithXpath(component, expression) {\n findDOMNode = findDOM... | javascript | edit | 0 | 2 | mit | 0b527145181bc9f8aecf6a3f49eac23bccfba7eb | relekang/chai-have-xpath,davija/chai-have-xpath | src/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport Client from './client'\nimport PullRequests from './pulls'\nimport Repositories from './repos'\nimport PageLinks from './paging'\n\nexport default function (config) {\n return new Client(config, {\n PullRequests,\n Reposit... | javascript | edit | 0 | 1 | mit | a0651499089a9cb5648b08713dc6f298ea667f94 | jamsinclair/github-lite | src/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst chai = require('chai');\nconst chaiAsPromised = require('chai-as-promised');\nconst nock = require('nock');\n\nchai.use(chaiAsPromised);\nchai.should();\nconst expect = chai.expect;\n\nconst pnut = require('../lib/pnut');\n\ndescr... | javascript | edit | 0 | 1 | mit | 822a4132d2bb0e85372e8f7790b9bd4db9c5f17e | kaiwood/pnut-butter | test/pnut.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/* global atom:true */\nconst _ = require('underscore-plus');\nconst clipboard = atom.clipboard;\n\nmodule.exports =\nclass KillRing {\n constructor(limit=16) {\n this.buffer = [];\n this.sealed = true;\n this.limit = limit;\n... | javascript | edit | 0 | 2 | mit | 9d90cb8c5f2b2b38c85bb80fe96cab2b6037d35c | yasuyuky/transient-emacs,yasuyuky/transient-emacs | lib/kill-ring.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar assert = require('assert');\nvar configMergeLoader = require('../index.js');\n\ndescribe('configMergeLoader', function() {\n it('should return an function', function() {\n assert.equal(typeof configMergeLoader, 'function');\n }... | javascript | edit | 0 | 1 | mit | ee239ef4415590d899a71d8e42038a8bcd831f18 | bitfyre/config-merge-loader | test/test.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n(function(ns) {\n\n var namespaces = [this];\n\n var attachBehavior = function($element, behavior) {\n var fn = namespaces;\n\n behavior.replace(/([^.]+)/g, function(object) {\n if(fn === namespaces) {\n ... | javascript | edit | 0 | 5 | mit | 535f14e8f463ce81d360204fde459c3ca3e49f97 | elementaljs/elementaljs,elementaljs/elementaljs | src/elemental.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport Finity from '../../src';\n\nconst submachineConfig = Finity\n .configure()\n .initialState('substate1')\n .getConfig();\n\nconst stateMachine = Finity\n .configure()\n .initialState('state1')\n .on('event1').transit... | javascript | edit | 0 | 1 | mit | 0e1a7d0eccd55f3a45f39794e17c4cfea6912b3b | nickuraltsev/fluent-state-machine,nickuraltsev/finity,nickuraltsev/finity | examples/hierarchical/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport React, { Component } from 'react';\nimport ReactDom from 'react-dom';\nimport YTSearch from 'youtube-api-search';\nimport SearchBar from './components/search_bar';\nimport VideoList from './components/video_list';\nimport VideoDe... | javascript | edit | 0 | 1 | mit | 6b8328476ac25514dba5204ee3e3fbe423539fd0 | JosephLeon/redux-simple-starter-tutorial,JosephLeon/redux-simple-starter-tutorial | src/index.js | rejected_duplicate | Near-duplicate of sample 69811 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport marked from 'marked';\nimport htmlclean from 'htmlclean';\nimport he from 'he';\n\nconst renderer = new marked.Renderer();\n\nrenderer.listitem = (text) => {\n if (/<input[^>]+type=\"checkbox\"/.test(text)) {\n return `<li cl... | javascript | edit | 0 | 2 | mit | 338d11b74b6ebcbc841688d21e17a296288dba1d | oneteam-dev/draft-js-oneteam-rte-plugin,oneteam-dev/draft-js-oneteam-rte-plugin | src/encoding/markdownToHTML.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\ndescribe('Address Book', function() {\n\tvar addressB,\n\t\tthisContact;\n\n\tbeforeEach(function() {\n\t\taddressB = new addressBook();\n\t\tthisContact = new Contact();\n\t});\n\n\tit('should be able to add a contact', function() {\n\... | javascript | edit | 0 | 1 | mit | e91fac319f8c5254569163f83908a676c6141f94 | AthinaB/js-testing-jasmine,AthinaB/js-testing-jasmine | spec/AddressBookSpec.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\"use strict\";\n\nvar request = require(\"supertest\");\n\nvar app = require(\"../js/server/app.js\");\n\ndescribe(\"App backend server\", function () {\n it(\"should serve the index page\", function (done) {\n request(app)\n... | javascript | edit | 0 | 1 | mit | b9cd5acaaf55baaac93f859699dc1fcbdb244dc5 | pixelistik/alreadydone,pixelistik/alreadydone,pixelistik/alreadydone | test/testIndex.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nApp.Store = DS.Store.extend({\n findQuery: function(type, id){\n id = id || {};\n id.api_key = App.API_KEY;\n\n return this._super(type, id);\n },\n\n allRecords: function(){\n var typeMaps = this.get('typeMaps'),\n ... | javascript | edit | 0 | 3 | mit | 1a12cf0c190e077d623f9a1fcad3f91cde5915c8 | Mause/tumblr-ember | src/js/app/data_utils/store.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport $ from 'jquery';\nimport Radio from 'backbone.radio';\nimport nprogress from 'nprogress';\nimport Application from '../common/application';\nimport LayoutView from './layout-view';\n\nlet routerChannel = Radio.channel('router');\... | javascript | edit | 0 | 2 | isc | 7b13df50ef46ddad708f0fd38c5d7f2891a1c56b | paulfalgout/marionette-strings,onelovelyname/marionette-wires,paulfalgout/marionette-strings,batpad/marionette-wires-tada,yuya-takeyama/marionette-wires,thejameskyle/marionette-wires,onelovelyname/marionette-wires,jkappers/marionette-wires,yuya-takeyama/marionette-wires,thejameskyle/marionette-wires,batpad/marionette-w... | src/application/application.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * `npm run ci:clean`\n *\n * Cross-platform script to remove report directory for CI.\n */\nconst process = require('process');\nconst script = require('./script');\n\nconst reportDirPath = process.env.npm_package_config_report_di... | javascript | edit | 0 | 0 | mit | 75d150dcbe15649754248f8628e136a7c40f7eab | choonchernlim/front-end-stack,choonchernlim/front-end-stack | scripts/ci-clean.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar computedStyle = require('computed-style');\n\nmodule.exports = function(container) {\n if (!container) { return; }\n\n var children = [].slice.call(container.children, 0).filter(function (el) {\n var pos = computedStyle... | javascript | edit | 0 | 4 | mit | 27e7db50ae93d77c8578a4b104efe3f56fce064e | gardr/ext,gardr/ext | src/childrensize.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n// @AngularClass\n\nexports.config = {\n baseUrl: 'http://localhost:8080/',\n\n allScriptsTimeout: 11000,\n\n framework: 'jasmine',\n\n jasmineNodeOpts: {\n defaultTimeoutInterval: 60000,\n showTiming: true\n },\n\n capabili... | javascript | edit | 0 | 1 | mit | 968fae71469a3bb8a010f74c2c8244a4d26f429d | burgerga/angular2-webpack-starter,benjaminleetmaa/hsoemRepo,psamit/angular-starter,Yaroslav-Andryushchenkov/epam-angular2,JerrolKrause/angular-ultimate-starter,vamurov/lazyImageLoad,bryant-pham/easyjudge,shattar/test-ng2-submodule-routing,stepkraft/factory-queue,DigitalGeek/angular2-webpack-starter,davidstellini/bvl-pa... | protractor.conf.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n */\n\nimport { statement } from '../../..... | javascript | edit | 0 | 1 | mit | b3b75a6855b143e1e5fb208419eea2b8819b618d | reactjs/react-docgen,reactjs/react-docgen,reactjs/react-docgen | src/utils/__tests__/isExportsOrModuleAssignment-test.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar RESET_TIME = 3000;\nvar timeout;\nvar lastPress = Date.now();\nvar average = 0;\nvar iterations = 1;\n\nchrome.browserAction.onClicked.addListener(function() {\n var elapsedTime = Date.now() - lastPress;\n lastPress = Date.now();\... | javascript | edit | 0 | 2 | mit | 02e71c3c22b5563f05910a92bc1c7efa9cc7a3a9 | chrisblazek/bpm-tapper,chrisblazek/bpm-tapper,chrisblazek/bpm-tapper | src/background.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar _ = require('lodash-node/modern')\n\n// TODO: consider passing the taxonomy types to the constructor\nfunction PostManager() {\n this.posts = []\n}\n\nPostManager.prototype.all = function() {\n return posts\n}\n\nPostManager.proto... | javascript | edit | 0 | 2 | mit | 7cb07d2328863847644887eff660978e0699e22b | philipwalton/ingen | lib/post-manager.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nvar deferred = require('deferred')\n , fs = require('fs')\n , extname = require('path').extname\n\n , hasNodeSheBang = RegExp.prototype.test.bind(/^#![\\u0021-\\uffff]+(?:\\/node|\\/env node)\\s/)\n , promisi... | javascript | edit | 0 | 4 | isc | 3adfb577f9b4a5d7f28ccac40f17c867a6f7913c | medikoo/movejs,medikoo/rename-module | lib/is-js-module.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar express = require('express');\nvar bodyParser = require('body-parser');\nvar methodOverride = require('method-override');\nvar serveStatic = require('serve-static');\nvar errorhandler = require('errorhandler');\nvar less = require('... | javascript | edit | 0 | 5 | mit | 19ba468f68bab037a04277edae68fc94e89378e5 | KitaitiMakoto/express-droonga,droonga/express-droonga,droonga/express-droonga,KitaitiMakoto/express-droonga | lib/ui/dashboard.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar Statuses = require('../internalConstants').Statuses;\n\nfunction when(handlers) {\n handlers || (handlers = {});\n\n var status = this.status;\n var handler = handlers[status.toLowerCase()];\n\n if (!handler) {\n throw new Er... | javascript | edit | 0 | 6 | mit | daf3d146f9049a2ecc6cd732742fbc6d1b5ca2fc | kwangkim/marty,oliverwoodings/marty,bigardone/marty,martyjs/marty,kwangkim/marty,Driftt/marty,martyjs/marty,CumpsD/marty-lib,thredup/marty-lib,thredup/marty,bigardone/marty,kwangkim/marty,goldensunliu/marty-lib,martyjs/marty-lib,bigardone/marty,oliverwoodings/marty,Driftt/marty,gmccrackin/marty-lib,thredup/marty,KeKs0r... | lib/storeQuery/when.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\ndefine(['../math.js', '../../app/directives/graph_sketcher/GraphUtils.js'], function(m, graphUtils) {\n return {\n numOfPts: 100,\n\n lineStyle: function(pts) {\n\n let n = pts.length - 1;\n let co... | javascript | edit | 0 | 4 | mit | c8c85828f4a82f45484d868efed645041b698536 | ucam-cl-dtg/isaac-app,ucam-cl-dtg/isaac-app,ucam-cl-dtg/isaac-app,ucam-cl-dtg/isaac-app | app/js/lib/graph_sketcher/bezier.js | rejected_duplicate | Near-duplicate of sample 97113 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict'\n\n/**\n * @license\n * node-scrapy <https://github.com/eeshi/node-scrapy>\n * Copyright Stefan Maric, Adrian Obelmejias, and other contributors <https://github.com/eeshi/node-scrapy/graphs/contributors>\n * Released under ... | javascript | edit | 0 | 1 | mit | c59d6500c9bad9d0c2b3745c71010797c4a107fc | eeshi/node-scrapy | lib/query-parser.js | rejected_duplicate | Near-duplicate of sample 93284 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/* eslint-env node */\nmodule.exports = {\n extends: [ \"@vue/typescript\", \"./typescript.js\" ],\n parser: require.resolve(\"vue-eslint-parser\"),\n parserOptions: {\n parser: \"@typescript-eslint/parser\",\n so... | javascript | edit | 0 | 0 | mit | 135011f4551a81e7f57ad373ca8c25cdfde49032 | launchbadge/eslint-config-launchbadge | vue-typescript.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport { extend } from 'flarum/extend';\nimport DiscussionControls from 'flarum/utils/DiscussionControls';\nimport DiscussionPage from 'flarum/components/DiscussionPage';\nimport Button from 'flarum/components/Button';\n\nexport default... | javascript | edit | 0 | 3 | mit | c13e33eb935d74bd55b398cab0013df13a71210d | flarum/lock,flarum/lock | js/src/forum/addLockControl.js | rejected_duplicate | Near-duplicate of sample 90100 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n// Expose Raven to the world\nwindow.Raven = Raven;\n\n})(window);\n\n```\n\nApply this change: Make Raven compatible with CommonJS"
},
{
"role": "assistant",
"content": "\n// Expose Raven to the world\nif (typeof define ===... | javascript | edit | null | null | bsd-3-clause | f1e796076afa93d9f8a4e0b44434cd20695f3e29 | samgiles/raven-js,clara-labs/raven-js,PureBilling/raven-js,grelas/raven-js,danse/raven-js,getsentry/raven-js,danse/raven-js,getsentry/raven-js,samgiles/raven-js,benoitg/raven-js,eaglesjava/raven-js,housinghq/main-raven-js,getsentry/raven-js,vladikoff/raven-js,clara-labs/raven-js,Mappy/raven-js,hussfelt/raven-js,iodine/... | template/_footer.js | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar webpack = require(\"webpack\");\n\n/* eslint-disable no-undef */\nvar environment = process.env[\"NODE_ENV\"] || \"development\";\n\nmodule.exports = {\n\tentry: \"./src/game\",\n\toutput: {\n\t\tpath: __dirname + \"/build\",\n\t\tf... | javascript | edit | 0 | 0 | mit | 811816ad35cda5c1baa16d00ed20276faa052401 | RiseAndShineGames/BugCatcher,RiseAndShineGames/LudumDare35,RiseAndShineGames/Polymorphic,RiseAndShineGames/Polymorphic,RiseAndShineGames/BugCatcher,CaldwellYSR/Bug_Catcher,RiseAndShineGames/LudumDare35,SplatJS/splat-ecs-starter-project,SplatJS/splat-ecs-starter-project,CaldwellYSR/Bug_Catcher | webpack.config.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nmodule.exports = {\n entry: {\n javascript: \"./app/app.jsx\"\n },\n\n output: {\n path: __dirname,\n filename: \"bundle.js\"\n },\n\n resolve: {\n extensions: [\"\", \".json\", \".js\", \".js... | javascript | edit | 0 | 0 | apache-2.0 | 964f13a57f83d8418e8a9b82a0a93b5886862ff8 | anildigital/ruby-operators,anildigital/ruby-operators | webpack.config.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar path = require('path');\nvar CopyWebpackPlugin = require('copy-webpack-plugin');\n\nmodule.exports = {\n entry: [\n './js/index.js'\n ],\n output: {\n path: path.join(__dirname, 'dist'),\n filename: 'app.js'\n },\n mod... | javascript | edit | 0 | 0 | mit | 7f52d1670b86f9e750ada848b39a5e94417ed7ff | concord-consortium/portal-report,concord-consortium/portal-report,concord-consortium/portal-report,concord-consortium/portal-report | webpack.config.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\nconst webpack = require('webpack');\n\nconst env = process.env.NODE_ENV || 'development';\nconst isDev = env === 'development';\n\nconst devtool = isDev ? '#inline-source-map' : null;\nconst uglify = isDev ? null : new we... | javascript | edit | 0 | 1 | mit | d151aed6079c78314f2192a551c49d3fbd2e44d5 | akameco/PixivDeck,akameco/PixivDeck | webpack.config.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\ndescribe(\"Test the organismDetails file\", function() {\n\n it(\"Test for getBestName\", function() {\n expect(getBestName({})).toBe('');\n });\n});\n```\n\nApply this change: Expand test case for getBestName"
},
{
"role":... | javascript | edit | 0 | 1 | mit | 9697b8d10a8312fb9e07009ce62a8e380e68bc76 | molbiodiv/fennec,molbiodiv/fennec,molbiodiv/fennec,molbiodiv/fennec,molbiodiv/fennec | test/js/organismDetailsSpec.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst path = require('path');\nconst webpack = require('webpack')\n\nmodule.exports = {\n module: {\n rules: [\n {\n test: /\\.html$/,\n use: 'raw-loader'\n }\n ]\n },\n resolve: {\n... | javascript | edit | 0 | 0 | mit | 1a9912ec8f7579ddc1f440015933f905070b3974 | iFixit/pulldasher,iFixit/pulldasher,iFixit/pulldasher,iFixit/pulldasher | webpack.config.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n#!/usr/bin/env node\nrequire('shelljs/global');\nrequire('colors');\n\nvar async = require('async'),\n ESLintCLIEngine = require('eslint').CLIEngine,\n\n LINT_SOURCE_DIRS = [\n './lib/runner',\n './lib/authorizer',\n... | javascript | edit | 0 | 5 | apache-2.0 | 83cb7f4c548d02de3d0ef1157e9a412e9a92f1f9 | postmanlabs/postman-runtime,postmanlabs/postman-runtime | npm/test-lint.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n#! /usr/bin/env node\n\nconst program = require('commander')\nconst PipelineRunner = require('../pipeline/runner')\n\nprogram\n .version('scry-css 0.2.0')\n .usage('[options] <type> <dir> <file...>')\n .option('-r --reporter [reporte... | javascript | edit | 0 | 1 | mit | 743f896c562cd8cc9089937fc69c2d89e62f2466 | ovidiubute/scry-css | src/bin/scry-css.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * @module ol/colorlike\n */\nimport {asString} from './color.js';\n\n\n/**\n * @param {ol.Color|ol.ColorLike} color Color.\n * @return {ol.ColorLike} The color as an ol.ColorLike\n * @api\n */\nexport function asColorLike(color) {... | javascript | edit | 0 | 3 | bsd-2-clause | 17455c2529c6dcbbee0fc21c8a89546be9472790 | ahocevar/ol3,stweil/openlayers,fredj/ol3,gingerik/ol3,mzur/ol3,openlayers/openlayers,stweil/ol3,oterral/ol3,stweil/openlayers,adube/ol3,ahocevar/ol3,stweil/ol3,geekdenz/ol3,mzur/ol3,fredj/ol3,tschaub/ol3,bjornharrtell/ol3,geekdenz/openlayers,fredj/ol3,geekdenz/openlayers,geekdenz/ol3,stweil/openlayers,tschaub/ol3,oterr... | src/ol/colorlike.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar fs = require('fs'),\n\tpath = require('path')\n\tfiles = fs.readdirSync(__dirname);\n\n// load in each file within this directory and attach it to exports\nfiles.forEach(function(file) {\n\t\n\tvar name = path.basename(file, '.js');... | javascript | edit | 0 | 3 | mit | 6a654de28eee0b37505e7623ddffcd3d1164a07d | linzjs/linz,linzjs/linz,linzjs/linz | middleware/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\"use strict\"\n\nlet express = require(\"express\");\nlet bodyParser = require('body-parser');\nlet cors = require('cors');\nlet app = express();\nlet { exec } = require('child_process')\n\napp.use(cors())\n// parse application/x-www-f... | javascript | edit | 0 | 2 | mit | 763798205711ef7b14876f47cda4dd63aaf21427 | projectOpenRAP/OpenRAP,projectOpenRAP/OpenRAP,projectOpenRAP/OpenRAP,projectOpenRAP/OpenRAP,projectOpenRAP/OpenRAP | devmgmtV2/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport React, { Component } from 'react';\nimport { connect } from 'react-redux'\nimport SearchBar from 'material-ui-search-bar'\nimport _ from 'lodash'\n\nimport './index.css'\nimport SearchResults from '../searchresults'\nimport { sea... | javascript | edit | 0 | 3 | bsd-3-clause | 61506b4ba4eb6ed3aadb5a02d802a92dfd520d36 | OpenChemistry/materialsdatabank,OpenChemistry/materialsdatabank,OpenChemistry/materialsdatabank,OpenChemistry/materialsdatabank | client/src/components/main/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\"use strict\";\n\nvar View = require(\"substance-application\").View;\nvar $$ = require(\"substance-application\").$$;\nvar Data = require(\"substance-data\");\nvar Index = Data.Graph.Index;\nvar _ = require(\"underscore\");\n\n// Subs... | javascript | edit | 0 | 2 | mit | 4ae5004078a0e79ce44b61f8f63d88cb87c6fab2 | substance/toc | toc_view.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nvar Y = require('yuidocjs');\nvar rsvp = require('rsvp');\nvar optsGenerator = require('../options');\n\nmodule.exports = {\n name: 'ember-cli-yuidoc',\n\n description: 'Generates html documentati... | javascript | edit | 0 | 1 | mit | a27f39fbdb3a23d2d4a8264bfa4f3ee4f7b2c701 | cibernox/ember-cli-yuidoc,cibernox/ember-cli-yuidoc,mixonic/ember-cli-yuidoc,mixonic/ember-cli-yuidoc,greyhwndz/ember-cli-yuidoc,greyhwndz/ember-cli-yuidoc,VladimirTyrin/ember-cli-yuidoc,VladimirTyrin/ember-cli-yuidoc | lib/commands/ember-cli-yuidoc.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n//Winston Logger Module\nconst winston = require('winston');\n\nlet logLevel = \"info\"; //default\nif (process.env.NODE_ENV === \"production\") {\n logLevel = \"error\"; //logs error\n}\nelse if (process.env.NODE_ENV === \"staging\"... | javascript | edit | 0 | 1 | bsd-3-clause | bf6d7c1082b2a9c7e80fdce81f2b3c159f4bc61a | renonick87/sdl_server,smartdevicelink/sdl_server,smartdevicelink/sdl_server,smartdevicelink/sdl_server,renonick87/sdl_server | custom/loggers/winston/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\n describe('layout tests', function () {\n\n it('Should have MaterialLayout globally available', function () {\n expect(MaterialLayout).to.be.a('function');\n });\n\n it('Should be upgraded to a MaterialLayout successful... | javascript | edit | 0 | 1 | apache-2.0 | 70dbfc53eecaa00ffc91c1b4c7dc63ae9a4ac653 | Ubynano/material-design-lite,NaveenNs123/material-design-lite,wonder-coders/material-design-lite,Mannaio/javascript-course,manohartn/material-design-lite,francisco-filho/material-design-lite,Creepypastas/material-design-lite,Ninir/material-design-lite,suman28/material-design-lite,rvanmarkus/material-design-lite,samthor... | test/unit/layout.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nvar exec = require('child_process').exec;\n\nfunction fail() {\n\tprocess.stdout.write(\n\t\t'Style check failed (see the above output).\\n' +\n\t\t'If you still wish to commit your code, run git commit -n to skip this ... | javascript | edit | 0 | 4 | mit | 6a04d1e2fee23066f9647a4caa38bea3395a4bf2 | GooTechnologies/goojs,GooTechnologies/goojs,GooTechnologies/goojs | tools/pre-commit.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\"use strict\";\nvar Codesearch = function() {\n return {\n socket: null,\n delegate: null,\n connect: function(delegate) {\n if (Codesearch.socket !== null)\n return;\n console.log(\"Connecting...\");\n ... | javascript | edit | 0 | 2 | bsd-2-clause | 6adaa4847545b2ba7564bfc952a542d1ac9d5629 | lekkas/livegrep,paulproteus/livegrep,wfxiang08/livegrep,wfxiang08/livegrep,paulproteus/livegrep,wfxiang08/livegrep,lekkas/livegrep,lekkas/livegrep,lekkas/livegrep,lekkas/livegrep,paulproteus/livegrep,paulproteus/livegrep,lekkas/livegrep,paulproteus/livegrep,paulproteus/livegrep,wfxiang08/livegrep,wfxiang08/livegrep,wfx... | web/static/codesearch.js | rejected_duplicate | Near-duplicate of sample 83229 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport React, { Component } from 'react';\n\nclass RowSizeControls extends Component {\n render() {\n return (\n <div style={{textAlign: 'center'}}>\n <label>Images per row</label>\n <input\n style={{\n ... | javascript | edit | 0 | 1 | mit | 94e178e8e3cea8c4f0ebd32b7b47ffea9da6ee78 | stevula/gallery,stevula/gallery | src/RowSizeControls/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * Return a truncated version of a string\n * @param {string} input \n * @param {integer} length \n * @param {boolean} killwords \n * @param {string} end \n * @return {string} \n */\nPolymerExpressions.pro... | javascript | edit | 0 | 8 | apache-2.0 | 0cf9aa8f61ccfc3720de7a2d9d017c97c1b79205 | addyosmani/polymer-filters,eumendoza/polymer-filters,addyosmani/polymer-filters,eumendoza/polymer-filters | filter-truncate.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport React from 'react';\n\nimport LoadingContainer from '../containers/LoadingContainer';\nimport PathResultsContainer from '../containers/PathResultsContainer';\nimport ErrorMessageContainer from '../containers/ErrorMessageContainer... | javascript | edit | 0 | 1 | mit | 70b48677ffeb89bdc83cfd6dd0e645a613d2593c | jwngr/sdow,jwngr/sdow,jwngr/sdow,jwngr/sdow | website/src/components/Home.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nmodule.exports = function(html, attachments) {\n attachments.forEach(function(attachment) {\n attachment.applied = false;\n\n var regexps = [\n (attachment.fileName) ? new RegExp('<img[^>]*cid:' + attachment... | javascript | edit | 0 | 5 | mit | 6053b42bcf2d2cfe9604f9923b06b9a0151f3b15 | AnyFetch/npm-cid | lib/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict'\n\nconst _ = require('lodash')\n\nconst hasLoop = (flow) => {\n if (Array.isArray(flow)) {\n return _validate(flow)\n } else if (flow.states) {\n return _validate(flow.states)\n }\n return {\n status: \"error\"... | javascript | edit | 0 | 3 | mit | f114a28c3c2d724712d992f7a81efa3604bcc224 | josemanu/flowx-loop-validator | lib/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\nseajs.on('compiled', function(mod) {\n if (mod.uri.indexOf('jquery.js') > -1) {\n window.jQuery = window.$ = mod.exports\n }\n})\n\nseajs.on('compile', function(mod) {\n if (mod.uri.indexOf('cookie.js') > -1) {\n mod.exports ... | javascript | edit | 0 | 2 | mit | 6c527183631acd6398ed279cb2f054a8672600c1 | coolyhx/seajs,yern/seajs,longze/seajs,MrZhengliang/seajs,lee-my/seajs,baiduoduo/seajs,liupeng110112/seajs,ysxlinux/seajs,yern/seajs,angelLYK/seajs,wenber/seajs,evilemon/seajs,wenber/seajs,miusuncle/seajs,lee-my/seajs,yuhualingfeng/seajs,LzhElite/seajs,121595113/seajs,judastree/seajs,wenber/seajs,twoubt/seajs,eleanors/S... | tests/specs/extensible/auto-transport/main.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/*=include modules/accessor.js */\n/*=include modules/ajax.js */\n/*=include modules/calculation_colums.js */\n/*=include modules/clipboard.js */\n/*=include modules/download.js */\n/*=include modules/edit.js */\n/*=include modules/filt... | javascript | edit | 0 | 0 | mit | 1610d0389c7e0a7a10988d191e6dd3a08ea8712d | olifolkerd/tabulator | src/js/modules_enabled.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar easymongo = require('easymongo');\n\nmodule.exports = function(options) {\n var mongo = new easymongo(options);\n\n return {\n find: function(collection, params, options) {\n return function(fn) {\n mongo.find(colle... | javascript | edit | 0 | 1 | mit | ffcf2e2ff94d8abc2e2b047ccd975be7449ee198 | meritt/co-easymongo | lib/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar debug = require('debug')('metalsmith-copy'),\n path = require('path'),\n cloneDeep = require('lodash').cloneDeep;\n minimatch = require('minimatch');\n\nmodule.exports = plugin;\n\nfunction plugin(options) {\n return funct... | javascript | edit | 0 | 7 | mit | 28a68feafafc98c1fa981751785c4319fd64ac60 | mattwidmann/metalsmith-copy | lib/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nconst gulp = require('gulp');\nconst helper = require('gulp/helper');\n\ngulp.task('configure:sandbox', cb => {\n const isNotEmpty = helper.validators.isNotEmpty;\n const questions = [\n {\n type: 'input',\n ... | javascript | edit | 0 | 2 | mit | 038c140deb2618833172bd48c59adb7f21e49205 | radekk/webtask-mfa-monitor,radekk/mfa-monitor,radekk/webtask-tfa-monitor | gulp/tasks/configure.sandbox.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\nvar tools = module.exports = exports = {},\n debug = require('debug')('turnkey');\n\ntools.default_cfg = function() {\n var cfg = {\n // Required Options --------------------------------------------------------\n router: und... | javascript | edit | 0 | 3 | mit | 0a2be4064b2ec75d428f55861f2c8d35727a0ee5 | uhray/turnkey | lib/tools.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/* eslint-env node */\n\nmodule.exports = {\n root: true,\n parser: '@typescript-eslint/parser',\n parserOptions: {\n ecmaFeatures: {\n jsx: true,\n },\n ecmaVersion: 2020,\n sourceType: 'module',\n },\n plugins: [... | javascript | edit | 0 | 0 | mit | 263f22fb4a56ede32e07f455db8a0e5a02e5dab2 | hugo/hugo.github.com,hugo/hugo.github.com | .eslintrc.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport React from 'react'\n\nexport const Checkbox = ({ id, nodes, onToggle }) => {\n const node = nodes[id]\n const { key, childIds, checked } = node\n\n const handleChange = () => {\n onToggle(id)\n }\n\n return (\n <React.... | javascript | edit | 0 | 3 | mit | e67bf05ecc75244b5b54020939f177b715168f70 | joelgeorgev/react-checkbox-tree,joelgeorgev/react-checkbox-tree | src/components/Checkbox.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst theme = {\n color: {\n grey: '#DDDDDD',\n black: '#111111',\n },\n font: {\n sans: `'Lora', sans-serif`,\n serif: `'Raleway', serif`,\n },\n};\n\nexport default theme;\n\n```\n\nApply this change: Add sizes to make... | javascript | edit | 0 | 0 | mit | f581907321b60c1bfc0db9dff09b9028a8b7f0f6 | raulfdm/cv | src/styles/theme.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n(() => {\n const $input = document.querySelector('#pull_request_body');\n if (!$input || $input.textLength > 0) {\n return;\n }\n\n jiraLinks = [];\n document.querySelectorAll('.commit-message').forEach((commitMessage) => {\n ... | javascript | edit | 0 | 6 | mit | e661eea9ec561302f48d24dd6b8ed05d262240ad | marionm/pivotal-github-chrome,marionm/pivotal-github-chrome | add-jira-links-to-description.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/*\n * style-select.js\n * https://github.com/savetheinternet/Tinyboard/blob/master/js/style-select.js\n *\n * Changes the stylesheet chooser links to a <select>\n *\n * Released under the MIT license\n * Copyright (c) 2013 Michael Save... | javascript | edit | 0 | 2 | mit | 84de059065c054adce97cf295bc3086664d68f0f | Admin-Kaf/Tinyboard,Admin-Kaf/Tinyboard,Admin-Kaf/Tinyboard,Admin-Kaf/Tinyboard | js/style-select.js | rejected_duplicate | Near-duplicate of sample 70326 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n$(document).ready(function() {\n $('#upload_form').change(function () {\n $('#upload_form_label').hide(); \n $('#upload_form').hide(); \n $('#upload_progress').show(); \n $('#upload_form').submit();\n });\n \n $('#propag... | javascript | edit | 0 | 1 | mit | e06d0ff85d4989a0e981fb33f836baef23d1bc3d | scottwillson/racing_on_rails,scottwillson/racing_on_rails,scottwillson/racing_on_rails,scottwillson/racing_on_rails | app/assets/javascripts/events.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport reducer from './';\n\ndescribe('Modal reducer', () => {\n let initialState;\n let state;\n let actionType;\n let payload;\n\n const callReducer = () => reducer(state, { type: actionType, payload });\n\n beforeEach(() => {\n... | javascript | edit | 0 | 1 | mit | 73464c8f531da3aa082f681fc263c1debcc7ad3f | fs/react-base,fs/react-base,fs/react-base | app/reducers/modal/index.test.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\ndaysUntilExpiration = function() {\n var daysToWait = 1;\n var daysAgo = new Date();\n daysAgo.setDate(daysAgo.getDate()-daysToWait);\n return daysAgo;\n}\n```\n\nApply this change: Change expiration to 90 days"
},
{
... | javascript | edit | 0 | 1 | mit | c593ba742b86fceb8fdb13a7aac7adfa0ea9a95f | tizol/wework,kaoskeya/wework,BENSEBTI/wework,chrisshayan/wework,num3a/wework,inderpreetsingh/wework,kaoskeya/wework,tizol/wework,EtherCasts/wework,nate-strauser/wework,princesust/wework,princesust/wework,chrisshayan/wework,BENSEBTI/wework,nate-strauser/wework,inderpreetsingh/wework,num3a/wework,EtherCasts/wework | lib/environment.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n// webpack config file for develop sugar.js\n\nmodule.exports = {\n\t'entry': './src/main/index',\n\t'output': {\n\t\t'path': './bundle',\n\t\t'library': 'Sugar',\n\t\t'libraryTarget': 'umd',\n\t\t'filename': 'sugar.js'\n\t},\n\t'module... | javascript | edit | 0 | 0 | mit | 354ace46a5860a938fb163b316e9c86dc60deae7 | tangbc/sugar,tangbc/sugar,tangbc/sugar | build/dev.sugar.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n// relay_force_routing\n\n// documentation via: haraka -h plugins/relay_force_routing\n\nexports.register = function() {\n this.register_hook('get_mx', 'force_routing');\n this.domain_ini = this.config.get('relay_dest_domains.ini'... | javascript | edit | 0 | 2 | mit | b2fb0e989f5e76838766b4a36572155d9c1b0847 | AbhilashSrivastava/haraka_sniffer,danucalovj/Haraka,Dexus/Haraka,haraka/Haraka,typingArtist/Haraka,msimerson/Haraka,abhas/Haraka,jjz/Haraka,niteoweb/Haraka,danucalovj/Haraka,MignonCornet/Haraka,baudehlo/Haraka,bsmr-x-script/Haraka,zombified/Haraka,MignonCornet/Haraka,Synchro/Haraka,fredjean/Haraka,MignonCornet/Haraka,b... | plugins/relay_force_routing.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nexport const baseStyles = {};\n\nexport const centerStyles = {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center'\n};\n\n```\n\nApply this change: Modify baseStyles & centerStyles for a better centering of the cont... | javascript | edit | 0 | 0 | mit | ce4d683bf0d7a47782646fcd140db12a10583c8f | teamleadercrm/teamleader-ui | .storybook/styles.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * Created by ogiba on 20.08.2017.\n */\n\nwindow.addEventListener(\"DOMContentLoaded\", function () {\n setupScrollListener();\n setupAlertListener();\n});\n\nfunction setupScrollListener() {\n var navBar = $('#nav-bar');... | javascript | edit | 0 | 2 | bsd-2-clause | 9de35c415a1cb7d976e674cffe46d9e5fac7f149 | ogiba/FamilyTree,ogiba/FamilyTree,ogiba/FamilyTree | web/assets/scripts/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport React, { PropTypes } from 'react';\nimport { Card } from '../UI';\nimport styles from './ImageCard.css';\n\nexport default class ImageCard extends React.Component {\n\n render() {\n const { onClick, onImageLoaded, image, text... | javascript | edit | 0 | 2 | mit | bf87ac15b529447a0906f47fdeeb842faa5739ff | dopry/netlify-cms,Aloomaio/netlify-cms,Aloomaio/netlify-cms,netlify/netlify-cms,netlify/netlify-cms,dopry/netlify-cms,netlify/netlify-cms,netlify/netlify-cms | src/components/Cards/ImageCard.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nmodule.exports = function (err, data) {\n\n if (err) {\n return 'Debug output: %j' + data + '\\n' + JSON.stringify(err);\n }\n\n if (!data.length) {\n return;\n }\n\n var returnString = '';\n for (var i = 0,... | javascript | edit | 0 | 4 | apache-2.0 | feeaac41b60172495adb7d60779ff0f1330dfa6f | chetanddesai/nsp,nodesecurity/nsp,requiresafe/cli,ABaldwinHunter/nsp-classic,ABaldwinHunter/nsp | lib/formatters/codeclimate.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst { APIMessage } = require('discord.js');\nconst { Extendable } = require('klasa');\nconst { TextChannel, DMChannel, GroupDMChannel, User } = require('discord.js');\n\nmodule.exports = class extends Extendable {\n\n\tconstructor(...... | javascript | edit | 0 | 3 | mit | 030839d136309e814d9da289c88662c025da833f | dirigeants/klasa | src/extendables/SendAliases.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nfunction AudioButton() {\n var that = this;\n this.position = {\n x: 15.5,\n y: 0.5\n };\n\n if (typeof localStorage.soundActivated === 'undefined') {\n localStorage.soundActivated = \"1\";\n }\n\n this.on = !!localStorag... | javascript | edit | 0 | 2 | apache-2.0 | 3dc61cf44f794cce36c4b008aeaa035cf37c8c76 | ninjadev/globalgamejam2016,ninjadev/globalgamejam2016 | client/src/AudioButton.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nmodule.exports = function(robot){\n\n\tvar pugBombReplies = [\n\t\t'There will be no more of that. Take your {{number}} pugs elsewhere.',\n\t\t'Nope. Nobody needs to see that many pugs.',\n\t\t'Why do you think we all need to see {{nu... | javascript | edit | 0 | 1 | mit | 6e60972f8c2fc04cfe34e5afcf793e9170fe0356 | BallinOuttaControl/bocbot,BallinOuttaControl/bocbot | scripts/pugbomb.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * @license\n * Copyright 2017 The FOAM Authors. All Rights Reserved.\n * http://www.apache.org/licenses/LICENSE-2.0\n */\n\nfoam.CLASS({\n package: 'foam.nanos.menu',\n name: 'SubMenu',\n extends: 'foam.nanos.menu.AbstractMenu'... | javascript | edit | 0 | 0 | apache-2.0 | e2eca91cfe4a7a13fa825b40815d0749cc11f989 | jacksonic/vjlofvhjfgm,jacksonic/vjlofvhjfgm,foam-framework/foam2,foam-framework/foam2,foam-framework/foam2,foam-framework/foam2,jacksonic/vjlofvhjfgm,foam-framework/foam2 | src/foam/nanos/menu/SubMenu.js | rejected_duplicate | Near-duplicate of sample 72758 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst axios = require('axios');\nconst chalk = require('chalk');\n\nconst helpers = require('../helpers');\n\nexports.listArticles = function (argv) {\n const articleCount = argv.limit > 1 ? argv.limit : 1;\n\n axios.get('https://api.... | javascript | edit | 0 | 3 | mit | 8286e9787c23e67c714918dd794b67e45c140128 | Belar/space-cli | src/modules/news.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport options from './options';\nimport { defer } from './util';\nimport { renderComponent } from './vdom/component';\n\n/** Managed queue of dirty components to be re-rendered */\n\n// items/itemsOffline swap on each rerender() call (... | javascript | edit | 0 | 5 | mit | f389dd376c8fc90e92eb643583afbc0a49dc8930 | neeharv/preact,developit/preact,gogoyqj/preact,neeharv/preact,developit/preact | src/render-queue.js | rejected_duplicate | Near-duplicate of sample 101538 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/* eslint-disable no-unused-vars*/\nimport React from 'react';\n/* eslint-enable no-unused-vars*/\nimport { Router, Route, IndexRoute } from 'react-router';\nimport createBrowserHistory from 'history/lib/createBrowserHistory';\n\nimport... | javascript | edit | 0 | 1 | mit | 34bf08d08b111fd67b2a346f8bcae1658fe68a51 | pl12133/pl12133.github.io,pl12133/pl12133.github.io | src/routes/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar TODO_COMPONENT = `\nvar TodoList = React.createClass({\n render: function() {\n var createItem = function(itemText, index) {\n return <li key={index + itemText}>{itemText}</li>;\n };\n return <ul>{this.props.items.map... | javascript | edit | 0 | 0 | bsd-3-clause | bf4bd191015a4f8994fa138bc95fec6fdd012e6b | AlmeroSteyn/react,reactkr/react,chippieTV/react,claudiopro/react,roth1002/react,airondumael/react,tomocchino/react,TheBlasfem/react,claudiopro/react,cody/react,TheBlasfem/react,terminatorheart/react,trueadm/react,jzmq/react,STRML/react,yangshun/react,ABaldwinHunter/react-engines,salzhrani/react,TheBlasfem/react,maxschm... | docs/_js/examples/todo.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport ObjectProxy from '@ember/object/proxy';\nimport { merge } from '@ember/polyfills';\n\n/**\n * @class Row\n * @extends Ember.ObjectProxy\n * @namespace SemanticUI\n */\nconst Row = ObjectProxy.extend({\n /**\n * Whether the row... | javascript | edit | 0 | 1 | mit | 8d40f4d706fa898002ea3b8cc33b38ab377befcb | quantosobra/ember-semantic-ui-table,quantosobra/ember-semantic-ui-table | addon/classes/row.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nmodule.exports = {\n \"extends\": [\n \"./index.js\",\n ],\n\n plugins: [\"fp\"],\n\n rules: {\n \"fp/no-arguments\": \"error\",\n \"fp/no-class\": \"warn\",\n \"fp/no-delete\": \"error\",\n \"fp/no-events\": \"error\... | javascript | edit | 0 | 0 | mit | 63fc607d48bf8e5439e6addc1cf3fc45adb444d4 | momentumft/eslint-config-momentumft | fp.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport 'react-native-browser-polyfill';\nimport App from './app/App.react';\nimport Component from 'react-pure-render/component';\nimport React, { AppRegistry, Platform } from 'react-native';\nimport config from './config';\nimport conf... | javascript | edit | 0 | 1 | mit | a5dbd6f84a5acc166dea63c4643ee543e5ec48a1 | TheoMer/este,vacuumlabs/este,christophediprima/este,TheoMer/Gyms-Of-The-World,christophediprima/este,skallet/este,este/este,steida/este,robinpokorny/este,syroegkin/mikora.eu,este/este,este/este,amrsekilly/updatedEste,robinpokorny/este,christophediprima/este,SidhNor/este-cordova-starter-kit,steida/este,TheoMer/Gyms-Of-T... | src/native/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst webpack = require('webpack')\nconst merge = require('webpack-merge')\nconst base = require('./webpack.base.config')\nconst path = require('path')\nconst VueSSRClientPlugin = require('vue-server-renderer/client-plugin')\n\nconst co... | javascript | edit | 0 | 0 | mit | 9e734eca0da3e455a11460b9e27b78254fa43809 | DivanteLtd/vue-storefront,pkarw/vue-storefront,pkarw/vue-storefront,DivanteLtd/vue-storefront,DivanteLtd/vue-storefront,pkarw/vue-storefront,pkarw/vue-storefront,DivanteLtd/vue-storefront | core/build/webpack.client.config.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * A simple Error type to represent an error that occured while loading a\n * resource.\n *\n * @class LoadError\n * @extends Error\n */\nexport default class LoadError extends Error {\n /**\n * Constructs a new LoadError with a... | javascript | edit | 0 | 2 | mit | 43646a6e0b8503ed8a6422037d25614a738b94e6 | ember-engines/ember-asset-loader,trentmwillis/ember-asset-loader,trentmwillis/ember-asset-loader,trentmwillis/ember-asset-loader,ember-engines/ember-asset-loader,ember-engines/ember-asset-loader | addon/errors/load.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n// This is a manifest file that'll be compiled into application.js, which will include all the files\n// listed below.\n//\n// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,\n// or a... | javascript | edit | 0 | 0 | mit | 540ec2d5e090e0e9740e00c90d4b4fd9ff09ca55 | dma315/ambrosia,dma315/ambrosia,dma315/ambrosia | app/assets/javascripts/application.js | rejected_duplicate | Near-duplicate of sample 71086 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport Em from 'ember';\n\nlet get = Em.get;\nlet defaultFilter = function(value) { return value; };\n\nexport default function(dependentKey, filter) {\n filter = filter || defaultFilter;\n\n let computed = Em.computed(function handle... | javascript | edit | 0 | 2 | mit | 82322ac222c9a0c6b3534270d38f063a3c67cf50 | GavinJoyce/ember-computed-change-gate,givanse/ember-computed-change-gate,GavinJoyce/ember-computed-change-gate,givanse/ember-computed-change-gate | addon/change-gate.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport CoreObject from 'fantasy-weather/models/_core/core-object';\nimport Team from 'fantasy-weather/models/team';\n\nlet League = CoreObject.extend({\n\n // Set defaults and stub out properties\n _defaults() {\n return {\n n... | javascript | edit | 0 | 1 | mit | fd1c12db210589a285b5917353e40714ca23e4b2 | rjhilgefort/nfl-weather,rjhilgefort/nfl-weather,rjhilgefort/nfl-weather | app/models/league.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n// namespace\nvar App = App || {};\n\nApp.Mob = (function () {\n \"use strict\";\n\n var fn = function (game, username, x, y) {\n Phaser.Sprite.call(this, game, x, y, 'alienBlue');\n this.game.physics.arcade.enable(t... | javascript | edit | 0 | 1 | mit | e9e8eb0a238a641c190f200b684fb3549b5a276d | hookbot/multi-player,hookbot/multi-player | src/objects/mob.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport React from \"react\";\nimport portal from \"react-portal-hoc\";\n\nconst MentionMenu = props => {\n const {\n active,\n className,\n item: Item,\n options,\n top,\n left,\n hoverItem,\n selectItem,\n s... | javascript | edit | 0 | 5 | mit | d6e3cdc458867d1aa90197b1b8b9a10ce65b9118 | mattkrick/react-githubish-mentions | src/MentionMenu.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport React, { Component } from 'react'\nimport { Link } from 'react-router'\n\nimport Header from 'Components/Header'\nimport Footer from 'Components/Footer'\nimport zhcn from '../../../intl/zh-cn'\nimport en from '../../../intl/en'\n... | javascript | edit | 0 | 3 | mit | 428785e0bbcb9b61b87eddf79e76e04d896be710 | jsconfcn/ningjs,jsconfcn/ningjs | src/Components/pages/Index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n#!/usr/bin/env node\nvar recast = require('recast');\nvar messages = require('./transform/messages');\nvar exec = require('child_process').exec;\nvar fs = require('fs');\nvar glob = require('glob');\nvar usage = [\n\t'Usage: assertion-m... | javascript | edit | 0 | 2 | mit | ad65d3a5d5419132635f188e90b3aa4e25626064 | bocoup/test262-v8-machinery,bocoup/test262-v8-machinery | scripts/assertion-messages.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nvar opbeat = require('../../');\nvar inquirer = require('inquirer');\n\nvar questions = [\n { name: 'app_id', message: 'App ID' },\n { name: 'organization_id', message: 'Organization ID' },\n { name: 'secret_token', ... | javascript | edit | 0 | 2 | bsd-2-clause | 23557892e740c28ea38304874636b3295e99a68c | opbeat/opbeat-node,driftyco/opbeat-node,opbeat/opbeat-node | test/scripts/cli.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/* global angular */\n\nangular\n .module('speciesApp')\n .factory('SpeciesService', [\n 'API_BASE_URL',\n '$resource',\n SpeciesService\n ])\n\nfunction SpeciesService (API_BASE_URL, $resource) {\n return $resource(\n A... | javascript | edit | 0 | 1 | mit | f9331ee186f212290d771fb10e45e1628b89b49f | stivaliserna/scripts,stivaliserna/scripts | species-explorer/app/services/species.service.js | rejected_duplicate | Near-duplicate of sample 85413 | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.