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(function (window, document) {\n\n let fields = Array.prototype.slice.call(\n document.querySelectorAll('input[data-provides=\"anomaly.field_type.datetime\"]')\n );\n\n // Initialize inputs\n fields.forEach(function (...
javascript
edit
0
4
mit
f8d630107e702eb9e445f00316e7293bbb712de6
anomalylabs/datetime-field_type,anomalylabs/datetime-field_type
resources/js/picker.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport apiConfig from '../../config/api'\nimport googleConfig from '../../config/google'\n\nfunction handleErrors (response) {\n if (response.status >= 200 && response.status < 300) {\n return response // .json()\n } else if (respo...
javascript
edit
0
6
mit
c9839bbe7c23d4149879a93b2113af5a06352aaf
clementgarbay/ExpenseTracker,clementgarbay/ExpenseTracker,clementgarbay/ExpenseTracker
src/services/api.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport './index.css';\nimport registerServiceWorker from './registerServiceWorker';\n\nclass App extends React.Component {\n render() {\n return <div>mo|flash-card...
javascript
edit
null
null
mit
40057aea3772aff2f1c67c6f6c1e1a35a80229f7
mishedone/mo-flash-cards,mishedone/mo-flash-cards
new/src/index.js
rejected_syntax
Syntax error detected by tree-sitter
false
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst utilities = require('./utilities');\n\nconst limited = (card) => card.limited ? ' | limited' : '';\nconst unique = (card) => card.unique ? ' | unique' : '';\nconst points = (card) => `${card.points}pt${card.points > 1 ? 's...
javascript
edit
0
2
mit
159a5caa2783309139ef0071b1624317422e8d4d
bmds/SlackXWingCardCmd
lib/templates.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport helpers from '../helpers';\nconst User = require('../models').User;\n\nmodule.exports = {\n create(req, res) {\n User.sync({ force: false }).then(() => {\n User\n .create({\n username: req.body.username,\...
javascript
edit
0
2
mit
cf9970d932aa757639931d271e990587fda4ad96
3m3kalionel/PostIt,3m3kalionel/PostIt
server/controllers/users.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nlet object1 = {};\nobject1.prop = 'exists';\nif (Object.hasOwn(object1, \"prop\")) {\n console.log(\"'prop' is own property\") // expected output: 'prop' is own property\n}\n\nobject1.prop_value_null = null;\nconsole.log(Object.hasOwn(...
javascript
edit
0
0
cc0-1.0
1db9d2c56309865716db80a0ea96c17429a0598f
mdn/interactive-examples,mdn/interactive-examples,mdn/interactive-examples
live-examples/js-examples/object/object-hasown.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar rp = require('request'),\n http = require('http'),\n https = require('https'),\n fileType = require('file-type');\n\nvar UrlChecker = function() {\n return this;\n}\n\nUrlChecker.prototype = {\n checkUrl: function(url...
javascript
edit
0
4
mit
289e8c2c468c4df9eb98d0c375ec7fdfebce07ad
victorgama/Giskard,victorgama/Giskard,victorgama/Giskard
src/adapters/debug/url_checker.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*!\n *\n * Web Starter Kit\n * Copyright 2014 Google Inc. All rights reserved.\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.\n * You ...
javascript
edit
0
1
mit
e1bf5e093e3ebd227e25a21f85785bf7fd8253f2
awayken/2015-Christmas-Card
app/scripts/main.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\"use strict\";\n\n$(\".nav a\").on(\"click\", function(){\n $(\".nav\").find(\".active\").removeClass(\"active\");\n $(\".nav\").find(\".active-re\").removeClass(\"active-re\");\n $(this).parent().addClass(\"active\");\n $(this...
javascript
edit
0
2
mit
24104d1f593509856c64a6b7aea6d58686744eaf
bow-paris/bow-paris.github.io,bow-paris/bow-paris.github.io
app/scripts/main.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*\n * Test _doListen function in net.js of haibu.carapace when there are multiple servers\n *\n */\nvar net = require('net'),\n port = 8000;\n\nvar server1 = net.createServer(function (socket) {\n});\n\nvar server2 = net.createServe...
javascript
edit
0
2
mit
f0b95277926775d0052b981ff475bb229b9d1c0c
nodejitsu/haibu-carapace,cozy/cozy-controller-carapace,nodejitsu/haibu-carapace
test/fixtures/multi-server.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nclass LoadingController {\n constructor($scope, $state, $interval) {\n 'ngInject';\n\n this.animTime = 850;\n this.ellipsis = '.';\n\n $scope.$on('server_disconnect', function(event, args) {\n alert('Server disconnecte...
javascript
edit
0
2
mit
ca80c6da2f5075ced8aa39f2e05d7988cece9c09
hendryl/Famous-Places-Mobile,hendryl/Famous-Places-Mobile
src/app/loading/loading.controller.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { RequestsControllerV2 } from '../../../controllers'\n\n\nexport default function addRoutes(app) {\n app.get('/v2/requests/:followedUserName/revoke', RequestsControllerV2.revokeRequest)\n}\n\n```\n\nApply this change: Change rev...
javascript
edit
0
1
mit
ad1b7d8adf25a4425ef6f86576b4c839a21b60b1
SiTLar/freefeed-server,FreeFeed/freefeed-server,FreeFeed/freefeed-server,SiTLar/freefeed-server,golozubov/freefeed-server,golozubov/freefeed-server
app/routes/api/v2/RequestsRoute.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\nvar utils = {\n find: (url, config) => {\n for (var key in config) {\n var item = config[key]\n if (item.domains.some((domain) => (url.host === domain))) {\n item.key = key\n return item\n }\n }\n ...
javascript
edit
0
5
mit
195595f9e6a95c904ae4cdbd942e940d7a61f96d
simov/styler
background/utils.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { AppRegistry } from 'react-native';\nimport { getStorybookUI, configure } from '@kadira/react-native-storybook';\nimport './addons';\n\n// import stories\nconfigure(() => {\n require('./stories');\n}, module);\n\nconst Storyboo...
javascript
edit
0
1
mit
247e569b42cc4504834c93e099696054d6b36aa6
rhalff/storybook,rhalff/storybook,storybooks/react-storybook,rhalff/storybook,bigassdragon/storybook,nfl/react-storybook,storybooks/react-storybook,bigassdragon/storybook,storybooks/storybook,rhalff/storybook,jribeiro/storybook,kadirahq/react-storybook,storybooks/storybook,shilman/storybook,jribeiro/storybook,rhalff/st...
generators/REACT_NATIVE/template/storybook/index.ios.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst ReactPrimitives = require('../ReactPrimitives');\nconst {\n Animated,\n StyleSheet,\n View,\n Text,\n Image,\n Platform,\n Touchable,\n Dimensions,\n Easing,\n} = require('react-native-web');\n\nReactPrimitives.inject({\n...
javascript
edit
0
2
mit
bea98066caadefa04d801d4d2c1e0e3af844b051
lelandrichardson/react-primitives,lelandrichardson/react-primitives,ktj/react-primitives,lelandrichardson/react-primitives,lelandrichardson/react-primitives
src/injection/react-native-web.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { moduleForComponent, test } from 'ember-qunit';\nimport hbs from 'htmlbars-inline-precompile';\n\nmoduleForComponent('flexberry-field', 'Integration | Component | flexberry field', {\n integration: true\n});\n\ntest('it renders...
javascript
edit
0
1
mit
90159c41efb05a7f29a76db4721f57ab713fc0ab
Flexberry/ember-flexberry,Flexberry/ember-flexberry,Flexberry/ember-flexberry,Flexberry/ember-flexberry
tests/integration/components/flexberry-field-test.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict'\n\nvar values = require('../sources/values')\nvar once = require('../sources/once')\n\n//convert a stream of arrays or streams into just a stream.\nmodule.exports = function flatten () {\n return function (read) {\n var...
javascript
edit
0
5
mit
38006447b94b9113998954f15b6b869313e09d9e
pull-stream/pull-stream,dominictarr/pull-stream
throughs/flatten.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// eslint-disable-next-line import/no-unresolved\nimport soundThumbnail from '!base64-loader!./sound-thumbnail.jpg';\n\nconst soundPayload = sound => {\n const assetDataUrl = sound.asset.encodeDataURI();\n const assetDataFormat = ...
javascript
edit
0
3
bsd-3-clause
40de587b0d0b69d18dec587183efcada5cad8bfd
LLK/scratch-gui,LLK/scratch-gui
src/lib/backpack/sound-payload.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst {Initializer, api} = require('actionhero');\nconst r = require('@lib/r');\nconst util = require('util');\n\nmodule.exports = class ApiInitializer extends Initializer {\n constructor() {\n super();\n this.name = 'a...
javascript
edit
0
1
mit
8fce9003d6ee62a57676807b7686cf43b69ed063
materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org
backend/servers/mcapid/initializers/api.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar signaller = require('..');\nvar messenger = require('rtc-switchboard-messenger');\n\nfunction createSignaller(opts) {\n return signaller(messenger(location.origin), opts);\n}\n\n// require('./all')(location.origin);\nrequire('rtc-s...
javascript
edit
0
1
apache-2.0
12b3d856e7e770e656fe1802e8cc21181ad8154b
eightyeight/rtc-signaller,rtc-io/rtc-signaller
test/all-browser.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar assign = require('object-assign');\nvar EventEmitter = require('events').EventEmitter;\n\nvar Dispatcher = require('../dispatcher');\n\nvar CHANGE_EVENT = 'change';\n\n/**\n * Creates a Flux Store.\n *\n * @pa...
javascript
edit
0
1
mit
05eb46cc5457f68eb5472bf044d91f609b3412e7
JanKuukkanen/teamboard-client-react,JanKuukkanen/teamboard-client-react,AatuPitkanen/teamboard-client-react,melonmanchan/teamboard-client-react,santtusulander/teamboard-client-react,melonmanchan/teamboard-client-react,JanKuukkanen/Oauth-client-react,JanKuukkanen/Oauth-client-react,nikolauska/teamboard-client-react,N4SJ...
src/scripts/utils/create-store.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar chakram = require('chakram'),\n expect = chakram.expect;\n\ndescribe(\"mPayroll API\", function() {\n\n it(\"should support POST request\", function () {\n this.timeout(4000);\n expect(chakram.post(\"http://local...
javascript
edit
0
1
mit
a0eb67c0e17d2dba35d6390326ec5d9a34eeb7f0
Bill-A/Correctness-DrivenDevelopment
test/mpayrollAPI.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst Decoder = require('../../../decoder')\nconst { parse } = require('../v3/response')\n\n/**\n * Starting in version 4, on quota violation, brokers send out responses\n * before throttling.\n *\n * OffsetCommit Response (Version: 4) ...
javascript
edit
0
1
mit
ccf742a2e643a1edded65bb31db58d812f43b248
tulios/kafkajs,tulios/kafkajs,tulios/kafkajs,tulios/kafkajs
src/protocol/requests/offsetCommit/v4/response.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { t } from './i18n'\n\nexport function capitalizeFirstLetter (string) {\n return string.charAt(0).toUpperCase() + string.slice(1)\n}\n\nexport function shortenNumber (number, decimals, abbreviate) {\n decimals = (decimals === u...
javascript
edit
0
6
mit
858d2ac59a025fd1907324dc6a8780fefa835b83
worldbank-cdrp/disaster-risk-explorer,worldbank-cdrp/disaster-risk-explorer,worldbank-cdrp/disaster-risk-explorer
app/assets/scripts/utils/format.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React, { Component } from 'react';\n\nimport UserInput from '../common/UserInput';\n\nexport default class App extends Component {\n constructor() {\n \tsuper();\n\n \tthis.state = { count: 0 };\n }\n\n onClickAddOne() {\n ...
javascript
edit
0
1
mit
1794c0dcf4b05ee1996db6ffd4c1cbf3c8502f1f
mcrice123/simple-react-example,mcrice123/simple-react-example
src/components/App/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React, { Component } from 'react'\nimport RandomNumber from '../RandomNumber'\nimport RoundImage from '../RoundImage'\nimport WelcomeNote from '../WelcomeNote'\nimport style from './style.css'\nimport classnames from 'classnames'...
javascript
edit
0
1
mit
a96dbaedf887cbf0d0770aedf6aea4fb222ef7bc
andreiconstantinescu/project-viper,andreiconstantinescu/project-viper
src/components/App/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// Returns binary string of given decimal number\n\nfunction decimalToBinary(num) {\n\tif (num >= 1) {\n\t\tif (num % 2) { // if decimal number is not divisible by 2, then recursively return proceeding binary of the digit minus 1, and t...
javascript
edit
0
3
mit
1c8f4060c48c394c16fd4a54128ec18549a125f3
derekmpham/interview-prep,derekmpham/interview-prep
binary-string.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\n// Just an example - you need to change your device id and access token\n\nvar url2SparkCore = \"https://api.spark.io/v1/devices/<your_device_id>/\"\nvar access_token_param = \"access_token=<your_access_token>\"\n\n```\n\nApply this c...
javascript
edit
0
0
mit
49495de5ba0784beae4cd675a885b80441cd75b6
pavelsuk/teatime,pavelsuk/teatime
web/js/private/sparkdevice.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n$(document).ready(function () {\n\n $(\"#pledge-payment-table\").DataTable(window.CRM.plugin.dataTable);\n\n\n $(\"#onlineVerify\").click(function () {\n $.ajax({\n type: 'POST',\n url: window.CRM.root + '/api/families/...
javascript
edit
0
2
mit
1c7614809bd8da78c203d2275beaf84bb5659330
ChurchCRM/CRM,ChurchCRM/CRM,ChurchCRM/CRM,ChurchCRM/CRM,ChurchCRM/CRM
src/skin/js/FamilyView.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = {\n handler: (msg, answer) => {\n if (msg.guild === undefined) return;\n\n const colorName = answer.rawArguments;\n\n if (colorName === '') {\n msg.reply('You must specify a colour. Use `bottie colours` t...
javascript
edit
0
5
apache-2.0
903d1c8eacb70ae8ddebad20577c3a7a886b5604
KetchupGirl/NotReallyABot,JPChat/NotReallyABot
src/commands/colour.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// @flow\n\nimport React, { Component } from 'react'\nimport type { Alert as AlertType } from '../types/application'\nimport type { clearAlert } from '../types/actions'\n\ntype Props = {\n alert: AlertType,\n clearAlert: clearAlert\n}...
javascript
edit
null
null
mit
4125c25bfaf12aeb90b2c3bb93cb42ddfa85ee2a
f96q/kptboard,f96q/kptboard,f96q/kptboard,f96q/kptboard
frontend/javascripts/components/Alert.js
rejected_syntax
Syntax error detected by tree-sitter
false
[ { "role": "user", "content": "Here is the current file:\n```javascript\nrequire('../../index.js');\nvar scope = require('./Tadpoles');\nscope.view.exportFrames({\n\tamount: 200,\n\tdirectory: __dirname,\n\tonComplete: function() {\n\t\tconsole.log('Done exporting.');\n\t},\n\tonProgress: function(event) {\n...
javascript
edit
0
1
mit
c67b8acd4ee31cd4f8285cd21185727d191d23ce
superjudge/paper.js,proofme/paper.js,ClaireRutkoske/paper.js,iconexperience/paper.js,mcanthony/paper.js,legendvijay/paper.js,Olegas/paper.js,lehni/paper.js,fredoche/paper.js,JunaidPaul/paper.js,lehni/paper.js,luisbrito/paper.js,baiyanghese/paper.js,Olegas/paper.js,JunaidPaul/paper.js,mcanthony/paper.js,baiyanghese/pape...
examples/Node.js/exportTadpoles.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react';\nimport ReactDOM from 'react-dom';\n\n/**\n * Mount any container component to a server rendered page.\n * @param {object} components - React components to attempt to mount\n */\nfunction mountContainer(compon...
javascript
edit
0
3
mit
b64f579fadf2f81c2df3060ac0108857e36c1d4f
DoSomething/rogue,DoSomething/rogue,DoSomething/rogue
resources/assets/utilities/MountContainer.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* @flow */\nimport { createSelector } from 'reselect';\nimport { getRawRealmEmoji } from '../directSelectors';\nimport { getAuth } from '../account/accountSelectors';\nimport { getFullUrl } from '../utils/url';\n\nexport const getAllRe...
javascript
edit
0
1
apache-2.0
25c6c9bdd3183fb5685b7486e3517e7aba85993d
vishwesh3/zulip-mobile,vishwesh3/zulip-mobile,vishwesh3/zulip-mobile,vishwesh3/zulip-mobile
src/emoji/emojiSelectors.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// Eloquent JavaScript\n\n// Run this file in your terminal using `node my_solution.js`. Make sure it works before moving on!\n\n// Program Structure\n// Write your own variable and do something to it.\n\n\n\n\n// Complete one of the ex...
javascript
edit
null
null
mit
0b855d32fe6610662427b656e66d841cda0f425d
Joshulu/phase-0,Joshulu/phase-0,Joshulu/phase-0
week-7/eloquent.js
rejected_syntax
Syntax error detected by tree-sitter
false
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst os = require('os');\nconst hostname = os.hostname();\n\nmodule.exports = robot =>\n robot.respond(/where are you/i, message => message.send(hostname))\n;\n\n```\n\nApply this change: Update to where are you" }, { "role": ...
javascript
edit
0
1
mit
f00005c5e8568be8ce800997c3360ed6a8676ab0
kwandrews7/slack-jarvis,kwandrews7/slack-jarvis
scripts/whereami.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\ndescribe('Controller: FormDropAreaCtrl', function () {\n\n // load the controller's module\n beforeEach(module('confRegistrationWebApp'));\n\n var FormDropAreaCtrl,\n scope;\n\n // Initialize the controller and a...
javascript
edit
0
1
mit
fcfab9205c9626f9735bebe27b19392eb178c86c
CruGlobal/conf-registration-web,CruGlobal/conf-registration-web,CruGlobal/conf-registration-web,CruGlobal/conf-registration-web
test/spec/controllers/formDropArea.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport updateComponent from './updateComponent';\n\nfunction applyState( component ) {\n\tconst blockRender = component._blockRender;\n\n\trequestAnimationFrame( () => {\n\t\tif ( component._deferSetState === false ) {\n\t\t\tcomponent....
javascript
edit
0
2
mit
4a4296951cd99e5507c4d93da805e90babc7f32e
trueadm/inferno,infernojs/inferno,infernojs/inferno,trueadm/inferno
src/core/applyState.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar AppPreferences = function () {};\n\nvar AppPreferencesError = function(code, message) {\n this.code = code || null;\n this.message = message || '';\n};\n\nAppPreferencesError.NO_PROPERTY = 0;\nAppPreferencesError.NO_PREFERENCE...
javascript
edit
0
3
mit
cf7f1d7f8452294718b28b247a0ce50cc0c34947
ledil/AppPreferences,chrisekelley/AppPreferences,ledil/AppPreferences,chrisekelley/AppPreferences
2.0.0/assets/www/applicationPreferences.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst chalk = require('chalk');\n\nmodule.exports = {\n\tlog: {\n\t\theading(text, color = 'white') {\n\t\t\tconsole.log(chalk[color].underline(`\\n${text}\\n`));\n\t\t},\n\t\terror(text) {\n\t\t\tthis.message(text, 'red');\n\t\t},\n\t\...
javascript
edit
0
1
apache-2.0
2bc7bb132e768eb395b97cedc9aa30f9ba438e57
weepower/wee,weepower/wee
build/utils.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* jshint node: true */\n\nmodule.exports = function(environment) {\n var ENV = {\n modulePrefix: 'dummy',\n environment: environment,\n baseURL: '/',\n locationType: 'auto',\n EmberENV: {\n EXTEND_PROTOTYPES: false...
javascript
edit
0
4
mit
711ca399444c2b9821131b1b001b50be3ffb6a96
flexyford/ember-collection,paddyobrien/ember-collection,arenoir/ember-collection,nkgm/ember-collection,nkgm/ember-collection,emberjs/ember-collection,emberjs/ember-collection,flexyford/ember-collection,arenoir/ember-collection,paddyobrien/ember-collection
tests/dummy/config/environment.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* jshint node: true */\n\nmodule.exports = function(environment) {\n var ENV = {\n modulePrefix: 'dummy',\n environment: environment,\n baseURL: '/',\n locationType: 'auto',\n EmberENV: {\n FEATURES: {\n // ...
javascript
edit
0
4
mit
c51c5897c99287089c605fba126a910403614c8a
anilmaurya/ember-cli-holderjs,anilmaurya/ember-cli-holderjs
tests/dummy/config/environment.js
rejected_duplicate
Near-duplicate of sample 69089
true
[ { "role": "user", "content": "Write javascript code for the following: Update from travis build of arcgis-dijit-drilldown" }, { "role": "assistant", "content": "define([\"dojo/_base/declare\",\"./_LocatorBase\"],function(a,b){return a([b],{locatorType:\"OSG\",resultsPickList:null,streetGrouping:...
javascript
new_file
0
1
apache-2.0
442298f2a4198429172ca3a0df85e196798485b7
EsriUK/wab-dijit-drilldown,EsriUK/wab-dijit-drilldown
Drilldown/Drilldown/Locators/OSGLocator.js
rejected_duplicate
Near-duplicate of sample 89234
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { Meteor } from 'meteor/meteor';\nimport { Match, check } from 'meteor/check';\n\n\nMeteor.publish('modules', function(limit, PUField, regionField, search) {\n check(search, Match.OneOf(String, null, undefined));\n check(region...
javascript
edit
0
5
mit
c298ee9ebddd040a79a2beb510a7ef7421bfb7dd
Kowalski985/Modulus,Kowalski985/Modulus
server/publications.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React, { Component } from 'react';\n\nimport {\n StyleSheet,\n Text,\n View,\n TouchableHighlight,\n} from 'react-native';\n\nclass Story extends Component{\n\n onProfilePressed() {\n this.props.navigator.push({\n ti...
javascript
edit
0
1
mit
b03d985cd1a43760c4acfc038e2b53502f43aa42
sf-red-pandas-2016/simul-react-native,sf-red-pandas-2016/simul-react-native,sf-red-pandas-2016/simul-react-native
simul/app/components/story.js
rejected_duplicate
Near-duplicate of sample 91306
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nMeteor.publish('posts', function(sort, limit) {\n return Posts.find({}, { sort: sort, limit: limit });\n});\n\nMeteor.publish('comments', function(postId) {\n check(postId, String);\n return Comments.find({ postId: postId });\n});\n\...
javascript
edit
0
1
mit
051b151d03d8533247666fb4989ca4cdd9576e78
Bennyz/microscope,Bennyz/microscope
server/publications.js
rejected_duplicate
Near-duplicate of sample 86219
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nApplication.Services.factory(\"sidebarUtil\", sidebarUtilService);\n\nfunction sidebarUtilService() {\n return {\n projectSize: function(project) {\n if (!('projectSize' in project)) {\n project.proje...
javascript
edit
0
3
mit
2b13f4f873c7c21e061eeb6c883d9e41d750695b
materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org
website/app/index/sidebar-util.js
rejected_duplicate
Near-duplicate of sample 86783
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { createStore, applyMiddleware } from 'redux';\nimport thunk from 'redux-thunk';\nimport rootReducer from '../reducers';\n\nconst configureStore = initialState =>\n createStore(rootReducer, initialState, applyMiddleware(thunk));...
javascript
edit
0
1
mit
f3c395e94ce65e496038de655a033ca2a79f118d
TrueWill/embracer,TrueWill/embracer
src/store/configureStore.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar hoverZoomPlugins = hoverZoomPlugins || [];\nhoverZoomPlugins.push( {\n name: 'Zhihu',\n prepareImgLinks: function(callback) {\n var res = [];\n hoverZoom.urlReplace(res,\n 'img[src*=\"zhimg.com\"]',\n...
javascript
edit
0
1
mit
ff3da7286a2c1df615f37fb2620cc922f44d3cdc
extesy/hoverzoom,extesy/hoverzoom
plugins/zhihu.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* @flow */\n'use strict';\n\nimport Relay from 'react-relay';\nimport React from 'react-native';\nconst { View, Text, Dimensions } = React;\n\nimport removeMarkdown from 'remove-markdown';\n\nimport Headline from '../text/headline';\ni...
javascript
edit
0
3
mit
12a8349823d056b88eb5091f9b4fa1b39e593933
artsy/emission,artsy/eigen,artsy/eigen,artsy/emission,artsy/eigen,artsy/eigen,artsy/eigen,artsy/emission,artsy/emission,artsy/emission,artsy/eigen,artsy/emission,artsy/emission,artsy/eigen
lib/components/artist/biography.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nexports.default = {\n\troutes: function (api) {\n\t\treturn {\n\t\t\tget: [\n\t\t\t\t/* URIs */\n\t\t\t\t{\n\t\t\t\t\tpath: '/:apiVersion/account/:accountHashId/monitor',\n\t\t\t\t\taction: 'monitorList'\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t...
javascript
edit
0
1
mit
1ef86a69fb010feea5a681829867821d9b8f298f
Flieral/Logger-Service
config/routes.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * Created by vytautassugintas on 06/04/16.\n */\n(function() {\n\"use strict\";\nangular.module(\"myApp\").constant(\"SERVER\", {\n\t\"ip\": \"http://openkudos.com/api\"\n})\n})();\n\n```\n\nApply this change: Change URL for the l...
javascript
edit
0
1
mit
7061004f786e5ed0398cc930cac1f1a44a0be456
open-kudos/open-kudos-intern-web,open-kudos/open-kudos-intern-web
src/app/services/server.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst repo = require('./persistence/storyRepo');\n\nexports.ping = (req, res) => {\n console.log(new Date(), 'ping');\n res.send({ salutation: 'pong' });\n};\n\nexports.searchStories = (req, res) => {\n console.log(new Date(), 'searc...
javascript
edit
0
1
mit
02b4b53a1de23ae0d0665f262340f79e527e75ae
happyspiritgames/storytime-service,happyspiritgames/storytime-service,happyspiritgames/storytime-service
src/storyController.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react';\nimport { gql, graphql } from 'react-apollo';\nimport FullSchedule from '../components/FullSchedule';\n\nfunction Schedule({ data }) {\n return (\n <div className=\"Container\">\n <h1 className=\"Page...
javascript
edit
0
1
mit
5593860773470cf42a73689017720cbab9ac6f65
urfonline/frontend,urfonline/frontend,urfonline/frontend
src/containers/Schedule.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React, { Component } from 'react';\nimport { render } from 'react-dom';\nimport { Provider } from 'react-redux';\nimport {Router, Route, Switch } from 'react-router-dom';\nimport style from '../public/style/style.scss';\nimport S...
javascript
edit
0
0
mit
539799bab3b2adf0af7a94ac9489d79e4f985096
amarachukwu-agbo/hello-books,amarachukwu-agbo/hello-books
client/src/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*\n CommentBox\n */\n\nvar CommentBox = React.createClass({\n render: function() {\n return (\n <div className=\"commentBox\">\n <h1>Comments</h1>\n <CommentList />\n <CommentForm />\n </div>\n );...
javascript
edit
0
1
mit
d8aeea70cd806fc1a78437bec67999821d10f20b
thinkswan/react-comments,thinkswan/react-comments
public/js/app.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\ndescribe('D3Funnel', function() {\n\tdescribe('constructor', function() {\n\t\tit('should instantiate without error', function() {\n\t\t\tnew D3Funnel('#funnel');\n\t\t});\n\t});\n\n\tdescribe('methods', function() {\n\t\tvar funnel, ge...
javascript
edit
0
1
mit
54b132e079d14a764c7c368fdae7f95dd3dcddc1
jakezatecky/d3-funnel,ollieRogers/d3-funnel,ollieRogers/d3-funnel,jakezatecky/d3-funnel
test/d3-funnel/d3-funnel.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\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 'Chrome'\n ],\n browser_args: {\n Chrome: {\n mode: 'ci',\n args: ...
javascript
edit
0
0
mit
6142571d4e980d3c39c82b697095871b1ecb0db3
fpauser/ember-cli,fpauser/ember-cli,mike-north/ember-cli,Turbo87/ember-cli,fpauser/ember-cli,jgwhite/ember-cli,mike-north/ember-cli,ember-cli/ember-cli,mike-north/ember-cli,balinterdi/ember-cli,buschtoens/ember-cli,Turbo87/ember-cli,balinterdi/ember-cli,asakusuma/ember-cli,jgwhite/ember-cli,ember-cli/ember-cli,raycohen...
blueprints/app/files/testem.js
rejected_duplicate
Near-duplicate of sample 73693
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\"use strict\";\nvar Cli = require(\"matrix-appservice-bridge\").Cli;\nvar log = require(\"./lib/logging\").get(\"CLI\");\nvar main = require(\"./lib/main\");\n\nconst REG_PATH = \"appservice-registration-irc.yaml\";\n\nnew Cli({\n r...
javascript
edit
0
2
apache-2.0
ae72c969997806ebba2d716425b975681703c6ac
matrix-org/matrix-appservice-irc,matrix-org/matrix-appservice-irc,matrix-org/matrix-appservice-irc
app.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* @flow */\nimport { AsyncStorage } from 'react-native';\nimport { applyMiddleware, compose, createStore } from 'redux';\nimport { persistStore, autoRehydrate } from 'redux-persist';\n\nimport rootReducer from './reducers';\nimport mid...
javascript
edit
null
null
apache-2.0
7af37613f1e2e22ff5ed5f8c8a2a014464dc58a9
vishwesh3/zulip-mobile,vishwesh3/zulip-mobile,vishwesh3/zulip-mobile,vishwesh3/zulip-mobile
src/boot/store.js
rejected_syntax
Syntax error detected by tree-sitter
false
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// Copyright 2014 The Chromium Authors. All rights reserved.\n// Use of this source code is governed by a BSD-style license that can be\n// found in the LICENSE file.\n\nimport * as Host from '../host/host.js';\nimport {KeyboardShortcut...
javascript
edit
0
2
bsd-3-clause
0051f88e457c2c70712c55a50ce2fd7be2a53bac
ChromeDevTools/devtools-frontend,ChromeDevTools/devtools-frontend,ChromeDevTools/devtools-frontend,ChromeDevTools/devtools-frontend,ChromeDevTools/devtools-frontend,ChromeDevTools/devtools-frontend
front_end/ui/ForwardedInputEventHandler.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport 'es6-promise/auto';\nimport Vuex from 'vuex';\n\nimport authStore from 'src/stores/auth-store';\nimport connectionStore from 'src/stores/connection-store';\n\n// Vue.use(Vuex);\n\nexport default new Vuex.Store({\n strict: true,\...
javascript
edit
0
0
mit
f248e289fbd7e80002dea4ab7e019182f87d86d6
tuelsch/bolg,tuelsch/bolg
src/config/store.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 * @format\n * @flow strict-local\n */\n\n...
javascript
edit
0
0
mit
3b813cade1f5d6f248a39f6bbd983f68c5794fe6
javache/react-native,javache/react-native,hoangpham95/react-native,exponentjs/react-native,javache/react-native,exponent/react-native,hammerandchisel/react-native,myntra/react-native,myntra/react-native,javache/react-native,hoangpham95/react-native,exponentjs/react-native,pandiaraj44/react-native,arthuralee/react-nativ...
Libraries/Renderer/shims/ReactFeatureFlags.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * mSupply Mobile\n * Sustainable Solutions (NZ) Ltd. 2019\n */\n\nimport Realm from 'realm';\n\nexport class Address extends Realm.Object {}\nexport class ItemCategory extends Realm.Object {}\nexport class ItemDepartment extends R...
javascript
edit
0
0
mit
6c45d8c16be766e6007ff44aa2b0c699fa5bf9be
sussol/mobile,sussol/mobile,sussol/mobile,sussol/mobile
src/database/DataTypes/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\ndefine(['backbone'], function(Backbone) {\n return Backbone.Model.extend({\n urlRoot: '/paste',\n defaults: {\n \"id\": null,\n \"syntax\": 'none',\n \"ttl\": 432000,\n \"password\": null,\n \"line_number...
javascript
edit
0
2
bsd-3-clause
0f5d262819ae08844156209714e56fa4e632eec7
gmr/privatepaste,blindsighttf2/privatepaste,Vicrelant/privatepaste
static/js/app/models/paste.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar commentForm = '<form id=\"comment_form\" action=\"/comments\" method=\"POST\" name=\"create_comment\">\n <textarea name=\"comment_form[body]\" placeholder=\"Write your comment here.\" required></textarea>\n <br>\n <input t...
javascript
edit
0
1
mit
8fc722b5df9635c4c8c88f3bbee4fcf46c0f08b7
great-horned-owls-2014/dbc-what-is-this,great-horned-owls-2014/dbc-what-is-this
app/assets/javascripts/comments.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nControllers.controller(\"ToolbarCtrl\", [\"$scope\", \"$rootScope\", \"Connection\", \"User\", \"Settings\", function ($scope, $rootScope, Connection, User, Settings)\n{\n $scope.user = User.get(\"~\");\n\n $scope.settings = $.pa...
javascript
edit
0
2
mit
a3da91b5f85a8900f9d7186c9e425b7c896d8667
coldstorm/coldstorm,coldstorm/coldstorm
app/scripts/controllers/toolbar.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nTwitter = {};\n\nvar urls = {\n requestToken: \"https://api.twitter.com/oauth/request_token\",\n authorize: \"https://api.twitter.com/oauth/authorize\",\n accessToken: \"https://api.twitter.com/oauth/access_token\",\n authenticate: ...
javascript
edit
0
1
mit
3e70d6e055866a8f315028632cba3fddb9fc4c37
chasertech/meteor,4commerce-technologies-AG/meteor,AnthonyAstige/meteor,DAB0mB/meteor,4commerce-technologies-AG/meteor,DAB0mB/meteor,jdivy/meteor,jdivy/meteor,lorensr/meteor,mjmasn/meteor,lorensr/meteor,Hansoft/meteor,mjmasn/meteor,AnthonyAstige/meteor,mjmasn/meteor,lorensr/meteor,mjmasn/meteor,jdivy/meteor,chasertech/...
packages/twitter/twitter_server.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport fs from 'fs-extra';\nimport path from 'path';\nimport { spawn } from 'child_process';\n\nconst directory = path.join(__dirname, '../dist');\nfs.mkdirs(directory, err => {\n if (err) {\n throw err;\n }\n const packageJsonPat...
javascript
edit
0
2
mit
2e8f10e18ab99c8b35a9f02e71c00e367c557899
merveilles/Rotonde,merveilles/Rotonde
packages/rotonde-deploy-now/src/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst Command = require('../Command');\n\nmodule.exports = Command.extend({\n commandName: 'ip',\n commandAliases: ['address', 'server'],\n processMessage: function (message, tokens) {\n return message.channel.send(this....
javascript
edit
0
1
isc
878251470116726529ab5373db3bb3f42e40ed3a
Shotbow/ChatBot
src/Command/IP.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = function (models) {\n const {\n Photo,\n User\n } = models;\n\n return {\n searchPhotos(pattern) {\n return new Promise((resolve, reject) => {\n Photo.find({\n ...
javascript
edit
0
2
mit
b4e44c88e784bcc3b1c3553c41ff61b5893fdec6
Bird-Shamaness/MuchPixels,Bird-Shamaness/MuchPixels
data/search-data.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n$(document).ready(function () {\n var $container = $('section.more');\n\n if ($container.find('.js-tabs').length) {\n $container.tabs();\n }\n});\n\n```\n\nApply this change: Add onclick handler for opening restricted windows.\n\n...
javascript
edit
0
2
mit
ebd39471326620bf454e6002cedf2117d2b43ad3
alphagov/frontend,alphagov/frontend,alphagov/frontend,alphagov/frontend
app/assets/javascripts/transactions.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport {describe, it} from 'mocha';\nimport {\n assertThat, equalTo,\n} from 'hamjest';\nimport {\n buildFunctionSpy, wasNotCalled, callCountWas, wasCalledWith,\n} from 'hamjest-spy';\n\nconst toSrcDestPairs = (files) => {\n return [...
javascript
edit
0
1
mit
18a4927355facf589cc0ddd9a83d88b130f8522a
tddbin/katas,tddbin/katas,tddbin/katas
src/deply.spec.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar dependencies = {\n 'concurrify': 'concurrify',\n 'denque': 'Denque',\n 'sanctuary-show': 'sanctuaryShow',\n 'sanctuary-type-identifiers': 'sanctuaryTypeIdentifiers'\n};\n\nexport default {\n input: 'index.cjs.js',\n external: ...
javascript
edit
0
0
mit
fae7c6d11b9ec6e0cfff121e470dece1f0ada08e
fluture-js/Fluture,fluture-js/Fluture,fluture-js/Fluture
rollup.config.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar React = require('react'),\n App = require('./App');\n\nReact.render(<App />, document.body);\n```\n\nApply this change: Fix bug filename : App -> app" }, { "role": "assistant", "content": "'use strict...
javascript
edit
0
0
mit
e9aa56d8bd74d9106921a7a3c57961da0d1eb6e1
gaearon/react-hot-loader,gaearon/react-hot-loader
packages/react-hot-boilerplate/scripts/index.js
rejected_duplicate
Near-duplicate of sample 82812
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\ndefine([\n \"hr/hr\",\n \"models/operation\",\n \"collections/operations\",\n \"text!resources/templates/operations/operation.html\"\n], function(hr, Operation, Operations, templateFile) {\n\n var OperationItem = hr.List....
javascript
edit
0
1
apache-2.0
4864f7e94be7bbf9241bb6f7980b3b0293ff0309
listepo/codebox,listepo/codebox,fly19890211/codebox,rajthilakmca/codebox,kustomzone/codebox,lcamilo15/codebox,lcamilo15/codebox,rodrigues-daniel/codebox,CodeboxIDE/codebox,ahmadassaf/Codebox,rodrigues-daniel/codebox,code-box/codebox,ronoaldo/codebox,blubrackets/codebox,quietdog/codebox,rajthilakmca/codebox,smallbal/cod...
client/views/operations/manager.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconsole.log(Intl.supportedValuesOf('calendar'));\nconsole.log(Intl.supportedValuesOf('collation'));\nconsole.log(Intl.supportedValuesOf('currency'));\nconsole.log(Intl.supportedValuesOf('numberingSystem'));\nconsole.log(Intl.supportedVa...
javascript
edit
0
0
cc0-1.0
dcb447516b46ae911a5c89390e5372c594978775
mdn/interactive-examples,mdn/interactive-examples,mdn/interactive-examples
live-examples/js-examples/intl/intl-supportedvaluesof.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar default_settings = {\n /* Topology settings */\n show_unused_interfaces: true,\n show_disconnected_hosts: true,\n show_topology: true,\n topology_transformation: 'translate(0,0) scale(1)',\n /* Map sett...
javascript
edit
0
0
mit
d9feb58a49cb211d8faa0e13980b4a28c1be5998
macartur/kytos,cemsbr/kytos,diraol/kytos,kytos/kyco,cemsbr/kytos,renanrodrigo/kytos,cemsbr/kytos,diraol/kytos,diraol/kytos,kytos/kytos
kytos/web-ui/static/js/kytos-settings.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\r\n\r\nvar DiscoverView = function() {\r\n\r\n this.initialize = function() {\r\n // 'div' wrapper to attach html and events to\r\n this.el = $('<div/>');\r\n };\r\n\r\n this.render = function() {\r\n\tif (!this....
javascript
edit
null
null
apache-2.0
c61a5de164a6530a193e058f0f53a434eef9963b
davidbwaikato/phonegap-fieldays-innovation,davidbwaikato/phonegap-fieldays-innovation,davidbwaikato/phonegap-fieldays-innovation,davidbwaikato/phonegap-fieldays-innovation
www/js/DiscoverView.js
rejected_syntax
Syntax error detected by tree-sitter
false
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nangular.module('adminApp')\n .directive('topMenu', ['$location', 'Menu', 'Auth', function ($location, Menu, Auth) {\n return {\n restrict: 'A',\n transclude: true,\n controller: function ($s...
javascript
edit
0
2
mit
ff91a7633eaf9be5aa9ac7d1fc5a362077dfadf4
fealaer/liltael.com,fealaer/liltael.com
client/scripts/admin/directives/topMenu.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\ns.Controls.Keyboard = function() {\n this.keyboard = new s.Keyboard();\n};\n\ns.Controls.Keyboard.prototype.update = function() {\n this.pitch = 0;\n this.roll = 0;\n this.yaw = 0;\n this.thrust = 0;\n this.fire = false;\n\n if (...
javascript
edit
0
11
bsd-2-clause
f08acfe17693bf58fe955c5892ead5e0be34e130
satellite-game/Satellite-Mobile
client/game/classes/s.Controls.Keyboard.js
rejected_complexity
Cyclomatic complexity too high: 11
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar ntfd = require('ntfd')\n\nntfd({\n path: __dirname + '/tests',\n agent: 'test',\n plugin: [\n new ntfd.plugin.ConsoleEmitter(),\n new ntfd.plugin.HttpEmitter('http://localhost:8000/api/suite/result'),\n ],\n test: {\n ...
javascript
edit
0
0
mit
a4d9a7dd9e8435a487e008ed28cb70afc22c788a
shutterstock/ntfd
example/tests.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// Factlink configuration\n//= require_tree ./globals\n\n// All the default libraries/files needed for all pages on Factlink\n//= require jquery_ujs\n//= require local_storage_polyfill\n//= require jquery_ujs_override\n\n//= require und...
javascript
edit
0
0
mit
7380e171b6d12a20b038e311f0856fe80d6f1a0f
Factlink/factlink-core,Factlink/factlink-core,daukantas/factlink-core,Factlink/factlink-core,daukantas/factlink-core,Factlink/factlink-core,daukantas/factlink-core,daukantas/factlink-core
core/app/assets/javascripts/application.js
rejected_duplicate
Near-duplicate of sample 72926
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n(() => {\n const $title = document.querySelector('.js-issue-title');\n if (!$title) {\n return;\n }\n\n chrome.storage.local.get('inlineLinks', (options) => {\n let title = $title.innerHTML.replace(/(<a[^>]+>|⬆︎|<\\/a>)/g, '')...
javascript
edit
0
3
mit
8e538785fb716e43e2f9a6b65114b9c30cc31b29
marionm/pivotal-github-chrome,marionm/pivotal-github-chrome
content.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\n(function (document) {\n document.addEventListener('DOMContentLoaded', function () {\n const details = document.getElementsByTagName('details');\n\n if (details.length <= 0 || typeof details[0].open ===...
javascript
edit
0
6
mit
a50e5099b166fd86ae0d4fad2872eb9f8b72bc0d
akilli/cms,akilli/cms,akilli/cms
gui/details.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { h, Component } from 'preact'\n\nexport default class extends Component {\n constructor() {\n super()\n this.state.show = false\n }\n linkState(key) {\n return e => this.setState({\n [key]: e.target.value\n }...
javascript
edit
0
2
mit
e62c5f46a629ef292be63f13212774e7ffce0b3c
zeusdeux/password-manager,zeusdeux/password-manager
views/components/addApp.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar Canal = require('../canal.js');\nvar expect = require(\"expect.js\");\n\ndescribe(\"Test Option\", function(){\n\nit(\"Some()\", function()\n{\n\tvar result = Canal.Some(1).map(function(d)\n\t{\n\t\treturn d + 1;\n\t}).collect();\n\...
javascript
edit
0
1
mit
fd3c129d69c6a1dad892f51d1e5c678c90a0525f
KerneLab/Canal,KerneLab/Canal
spec/test-Option.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = {\n\tpaths: {\n\t\thtml: {\n\t\t\tinline: {\n\t\t\t\tsrc: [ 'src/templates/**/*.html' ],\n\t\t\t\tdest: [ 'dist' ],\n\t\t\t},\n\t\t\tclean: {\n\t\t\t\tsrc: [ 'dist/**/*.html' ],\n\t\t\t\tdest: [ 'dist' ],\n\t\t\t},\n\t\...
javascript
edit
0
0
mit
6aa07e27b02e8d8f794fca57a7559ab676e38280
Slicejack/bojler,Slicejack/slicejack-email-boilerplate,Slicejack/bojler
gulp/config.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n#!/usr/bin/env osascript -l JavaScript\n\nObjC.import('stdlib')\n\nconst app = Application.currentApplication()\napp.includeStandardAdditions = true\n\nconst result = app.displayDialog('balenaEtcher wants to make changes. Type your pass...
javascript
edit
0
0
apache-2.0
bb04098062f84462200468159510cc4b77cb9ea5
resin-io/etcher,resin-io/herostratus,resin-io/resin-etcher,resin-io/resin-etcher,resin-io/etcher,resin-io/herostratus,resin-io/etcher,resin-io/etcher,resin-io/etcher
lib/shared/catalina-sudo/sudo-askpass.osascript.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { createStore, applyMiddleware } from 'redux'\nimport { routerMiddleware } from 'react-router-redux'\nimport TebukuroApp from '../reducers'\n\nexport default (preloadState = {}, history) => {\n return createStore(TebukuroApp, {}...
javascript
edit
0
1
bsd-3-clause
b395a3a7d6a8a9ee012fd90012f8fcb62e81e83d
gazayas/tebukuro,gazayas/tebukuro,ytorii/tebukuro,gazayas/tebukuro,ytorii/tebukuro,ytorii/tebukuro,ytorii/tebukuro,gazayas/tebukuro
front/client/store/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = function(source, map)\r\n{\r\n this.cacheable();\r\n\r\n source = '/* semantic-ui-react-loader */' + source;\r\n\r\n this.callback(null, source, map);\r\n};\n```\n\nApply this change: Implement import for component l...
javascript
edit
0
4
mit
9033ffbf7770e28f179276de156b3c981c9e5174
gadyonysh/semantic-ui-react-less-loader
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar extend = require('extend');\n\nvar repl = require('repl')\n , vm = require('vm')\n , fs = require('fs');\n\n\n/**\n * Start the REPL and expose variables in `context`.\n *\n * @arg {Object} context\n * @return {Re...
javascript
edit
0
2
mit
9af748a3d0067208436aea28b50bb7025bd0f798
eush77/nodei
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\n/**\n * Dependencies.\n */\n\nvar phonetics;\n\nphonetics = require('double-metaphone');\n\n/**\n * Change handler.\n *\n * @this {WordNode}\n */\n\nfunction onchange() {\n var data,\n value;\n\n data = thi...
javascript
edit
0
4
mit
ed4f7d0b575b1be84f25522a90c3a3f3ca7f2f2a
wooorm/retext-double-metaphone
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n#! /usr/bin/env node\n\"use strict\";\n\nconst login = require(\"facebook-chat-api\");\nconst giphy = require(\"giphy-api\")();\nconst confg = require(\"./config\");\n\nlogin({email: confg.EMAIL, password: confg.PASS}, function callback...
javascript
edit
0
8
mit
0e241dc6f2c969759d06f1f7333ae67f240a8d6a
kshvmdn/messengerbot
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = robot => {\n // Your plugin code here\n console.log('Yay, the plugin was loaded!', robot);\n\n // For more information on building plugins:\n // https://github.com/probot/probot/blob/master/docs/plugins.md\n\n // T...
javascript
edit
0
1
mit
945c74c81a2536c41116c314ba11189387803e0f
jarrodldavis/probot-gpg
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst nodemon = require(\"nodemon\")\n\nvar server\nvar started = false\nvar quit = false\n\nmodule.exports = function () {\n this.nodemon = function (opts) {\n return new Promise((resolve, reject) => {\n if (started) { server....
javascript
edit
0
2
mit
9715c30751cba4e4415677284a4505745e064704
MadcapJake/fly-nodemon
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar hbsDir = require('hbs-dir')\nvar change = require('change-case')\nvar path = require('path')\n\nmodule.exports = function (target, cb) {\n var opts = {\n origin: path.join(__dirname, './component-template/')\n , target: path.jo...
javascript
edit
0
1
mit
4da014438ea88e0223b5ab6a380ba39cc136de3c
Techwraith/ribcage-gen,cstumph/ribcage-gen,tedbreen/ribcage-gen,cstumph/ribcage-gen,Techwraith/ribcage-gen
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst mqtt = require('mqtt');\nconst mongoose = require('mongoose');\nconst Q = require('q');\n\nmongoose.Promise = Q.Promise;\nmongoose.connect('mongodb://localhost/home-data');\n\nconst client = mqtt.connect('mqtt://localhost')\n\ncl...
javascript
edit
0
1
apache-2.0
cf2bdc163670fbc2390de70e861d2dbcbe51153c
lino-silva/home-data-collector
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n#!/usr/bin/env node\n'use strict'\n\nvar url = require('url')\nvar normalizeUrl = require('normalize-url')\nvar chalk = require('chalk')\nvar arg = normalizeUrl(process.argv[2])\nvar http = require(arg.indexOf('https://') === 0 ? 'https...
javascript
edit
0
4
mit
d616b25bed4dba62c4f9b55a269055fc79deda08
watson/http-traceroute
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* jshint node: true */\n'use strict';\n\nmodule.exports = {\n name: 'ember-highlight',\n\n included: function(app, parentAddon) {\n var target = (parentAddon || app);\n\n target.import('vendor/simple.css');\n }\n};\n\n```\n\nA...
javascript
edit
0
1
mit
2951f5215d7eda07282311929c584c860b9a245b
knownasilya/ember-highlight,knownasilya/ember-highlight
index.js
accepted
null
true