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\nvar\n\tready = require('enyo/ready');\n\nvar\n\tstrawman = require('./src');\n\nready(function () {\n\tvar names = window.document.location.search.substring(1).split('&'),\n\t\tname = names[0],\n\t\tSample = strawman.samples[name] || st...
javascript
edit
0
2
apache-2.0
a137f99f06e149e5846e8c1ce44622a44ce3ab44
enyojs/enyo-strawman
moonstone-extra/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n$(document).ready(function(){\n // Twitter Bootstrap hack for menus on touch device\n $('body').on('touchstart.dropdown', '.dropdown-menu', function (e) { e.stopPropagation(); });\n\t\n $('a[rel=tooltip]').tooltip({\n co...
javascript
edit
0
1
mit
bf974d7a4d924c940f36935a0066ac6d860425d0
atamashi/GeneratorBundle,ksn135/GeneratorBundle,Restless-ET/GeneratorBundle,atamashi/GeneratorBundle,Restless-ET/GeneratorBundle,Lionel09/GeneratorBundle,RunOpenCode/GeneratorBundle,Lionel09/GeneratorBundle,RunOpenCode/GeneratorBundle,ksn135/GeneratorBundle,symfony2admingenerator/GeneratorBundle,ksn135/GeneratorBundle,...
Resources/public/js/admingenerator/general.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react';\nimport {Link} from 'react-router';\n\nexport default () => (\n <div>\n <h1>Hello world!</h1>\n <Link to=\"/other\">other</Link>\n </div>\n);\n\n```\n\nApply this change: Make Home a stateful component...
javascript
edit
0
1
mit
6f03c3bc20b5ad11d66c76d2e6e2fbc8edf50691
DAWZayas/Klayas,DAWZayas/Klayas
client/src/home/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { ConcatSource } from 'webpack-sources'\n\nexport default class DynamicChunksPlugin {\n apply (compiler) {\n const isImportChunk = /^chunks[/\\\\].*\\.js$/\n const matchChunkName = /^chunks[/\\\\](.*)$/\n\n compiler.plu...
javascript
edit
0
2
mit
2729de9c06a20f21b03e5d19cae4119f19c5a1a9
kpdecker/next.js
server/build/plugins/dynamic-chunks-plugin.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// database connection instance\nmodule.exports = {\n conn: function(){\n return require(\"massive\").connectSync({\n connectionString : \"postgres://databaseuser:password@host/database\" // if use ssl: ?ssl=true\"\n });\n ...
javascript
edit
0
0
mit
91cc4a4ec170de077bd22d9884a039a90aee8d13
aderbas/node-api-base
db/database.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport Marty from \"marty\";\nimport OrderConstants from \"../constants/orderConstants.js\";\n\nclass OrderActionCreators extends Marty.ActionCreators {\n creatFlight(flight, orderId, options) {\n this.dispatch(OrderConstants.CREATE...
javascript
edit
0
1
mit
07fb92502db2a2f915eb5014b9430cf48fde40bf
volkadserver/volkadserver-management-ui,volkadserver/volkadserver-management-ui
app/actions/orderActionCreators.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nconst path = require('path');\nconst fractal = module.exports = require('@frctl/fractal').create();\nconst pkg = require(path.join(__dirname, 'package.json'));\n\nfractal.set('project.title', 'Kanbasu');\nfractal.set('p...
javascript
edit
0
0
mit
8ea7bb6a659edf78f5440fcf28e2127e5c59ffbe
liip/kanbasu,liip/kanbasu
fractal.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\n/**\n * Module dependencies. Test commit\n */\nvar mongoose = require('mongoose'),\n passport = require('passport'),\n logger = require('mean-logger');\n\n/**\n * Main application entry file.\n * Please note that ...
javascript
edit
0
0
mit
81c2463ced66a32365d4702afeabfdb886222478
PankajMean/Note-Assignment,PankajMean/Note-Assignment
server.js
rejected_duplicate
Near-duplicate of sample 86600
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\"use strict\";\n\nvar components = require(\"server-components\");\nvar truncateHtml = require(\"truncate-html\");\nvar moment = require(\"moment\");\n\nvar feedparser = require('feedparser-promised');\nvar cache = require(\"memory-cac...
javascript
edit
0
3
mit
8e9a73248e5225a51de08f2c023927eb1e108fba
pimterry/tim.fyi,pimterry/tim.fyi
components/rss-source.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react'\nimport { useAuth } from 'use-auth0-hooks'\n\nimport NavLoginButton from './nav-login-button'\n\n/**\n * This component wraps NavLoginButton with Auth0 information.\n */\nconst NavLoginButtonAuth0 = ({\n class...
javascript
edit
0
2
mit
163ab0611d5588aacf5e29044730c66c4a8cd879
opentripplanner/otp-react-redux,opentripplanner/otp-react-redux,opentripplanner/otp-react-redux,opentripplanner/otp-react-redux
lib/components/user/nav-login-button-auth0.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport icon from 'react-icons/lib/fa/recycle'\n\nexport default {\n name: 'referenceTest',\n type: 'document',\n title: 'Reference test',\n description: 'Test cases for references',\n icon,\n fields: [\n {name: 'title', type: '...
javascript
edit
0
0
mit
f1ca66901a8b06b3d8dc5cd95048e4f470973966
sanity-io/sanity,sanity-io/sanity,sanity-io/sanity,sanity-io/sanity
packages/test-studio/schemas/references.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n//= require openseadragon\n\n(function($) {\n var __osd_counter = 0;\n function generateOsdId() {\n __osd_counter++;\n \n return \"Openseadragon\" + __osd_counter;\n }\n\n function initOpenSeadragon() {\n $('picture[data...
javascript
edit
0
2
mit
887c6d101040396d90a562ba9534b31eebe40b74
sul-dlss/openseadragon-rails,sul-dlss/openseadragon-rails
app/assets/javascripts/openseadragon/rails.js
rejected_duplicate
Near-duplicate of sample 87903
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*\n * Copyright 2014-2016 Hewlett-Packard Development Company, L.P.\n * Licensed under the MIT License (the \"License\"); you may not use this file except in compliance with the License.\n */\ndefine([\n 'backbone',\n 'i18n!find/...
javascript
edit
0
2
mit
2acd4efe76776c403e5cda0622e24a07602b818a
LinkPowerHK/find,hpe-idol/java-powerpoint-report,LinkPowerHK/find,hpe-idol/java-powerpoint-report,hpe-idol/find,hpautonomy/find,hpautonomy/find,hpautonomy/find,hpe-idol/find,hpe-idol/find,hpautonomy/find,hpe-idol/find,hpautonomy/find,LinkPowerHK/find,hpe-idol/find,LinkPowerHK/find,LinkPowerHK/find
find-core/src/main/public/static/js/find/app/page/search/spellcheck-view.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport Ember from \"ember\";\nimport DS from \"ember-data\";\n\nconst {\n get,\n inject: { service }\n} = Ember;\n\nexport default DS.JSONAPIAdapter.extend({\n namespace: 'api',\n drupalMapper: service(),\n\n pathForType(modelName)...
javascript
edit
0
2
mit
2dcd216fea2261894c9fec0550285282e0b38b2f
boztek/ember-data-drupal,boztek/ember-data-drupal
addon/adapter.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport * as yup from 'yup';\nimport i18next from '../../core/language';\n\nconst t = i18next.t.bind(i18next);\n\nexport default yup.object().shape({\n type: yup.string().oneOf(['caregiver', 'patient'], 'Please select a valid option'),\...
javascript
edit
0
0
bsd-2-clause
a7e11c898827eb8cfc979dbe0a8c113e9e8f689d
tidepool-org/blip,tidepool-org/blip,tidepool-org/blip
app/pages/prescription/prescriptionSchema.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use babel';\n\nfunction getClassLocalFields(tokens, editor) {\n return tokens\n .map(row => row.filter(token =>\n !token.scopes.includes('meta.method.body.java') &&\n token.scopes.includes('meta.definition.variable.java')...
javascript
edit
0
5
mit
e40a5a7323f40daf337c77c463622f082723cf81
noseglid/autocomplete-java-minus,noseglid/autocomplete-java-minus
lib/entryfinders/class-local-fields.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar convert = require('convert-source-map');\r\nvar type = require('../file-type');\r\n\r\nfunction getComment(map, fileType) {\r\n\r\n var mapConverter = convert.fromObject(map);\r\n\r\n switch (fileType) {\r\n\r\n case ty...
javascript
edit
0
3
bsd-3-clause
1a56bca5f095fc594b74de9ddb5dfac0bd49573c
ZocDoc/Bundler,ZocDoc/Bundler
src/file/source-map/get-source-map-comment.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar express = require('express');\nvar routes = require('./app/routes/index.js');\nvar mongoose = require('mongoose');\nvar passport = require('passport');\nvar session = require('express-session');\nvar bodyParser = re...
javascript
edit
0
1
mit
c6996eed7748dcf23522c8e914aabcda8135e948
CatherineBacon/voting-app,CatherineBacon/voting-app
server.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react'\nimport PropTypes from 'prop-types'\n\nimport { Modal, Button } from 'react-bootstrap'\n\nimport style from './style.css'\n\nconst CloseDialogConfirmation = ({ onYes, onNo }) => {\n return (\n <Modal show d...
javascript
edit
0
1
apache-2.0
ee38717049610149888a8f798aea1592f1d77b96
oVirt/ovirt-web-ui,mareklibra/userportal,mareklibra/userportal,mareklibra/userportal,oVirt/ovirt-web-ui,mareklibra/userportal,oVirt/ovirt-web-ui
src/components/CloseDialogConfirmation/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar\n env = process.env.NODE_ENV || 'development',\n config;\n\nconfig = {\n production : {\n db : {\n URL : process.env['wac_service_mongodb_url']\n },\n componentsURL : 'http://50.116.26.197/components/all',\n comp...
javascript
edit
0
0
mit
9c7362cb7aad3eb1ddf3c33715faa4b4662d36dc
web-audio-components/web-audio-components-service
config.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*\n ___ usage ___ en_US ___\n usage: prolific <protocol> <protocol args>\n\n --help display this message\n\n ___ $ ___ en_US ___\n\n udp is required:\n the `--udp` address and ...
javascript
edit
0
1
mit
47c8c5568c8c4a1d03ced69e53faba9a95e54642
bigeasy/prolific,bigeasy/prolific
prolific.supervisor/prolific.supervisor.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * No Description\n *\n * @author Erik E. Lorenz <<EMAIL>>\n * @license MIT License\n * @see LICENSE\n */\n\n/*\n * Random Test\n */\ndefine(function() {\n return function(QUnit, getModule) {\n var Random;\n\n Random = getMo...
javascript
edit
0
4
mit
3e215613d16354240303ccbb54413014da607216
elor/tuvero
scripts/core/test/random.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nlet webpack = require('webpack');\nlet WebpackDevServer = require('webpack-dev-server');\nlet config = require('./config/webpack.config.js');\n\nconst PORT = 9901;\n\n\nnew WebpackDevServer(webpack(config), {\n publicP...
javascript
edit
0
2
mit
06792e9b3c21ab30fe08e8d999edaa513fc14d91
AamuLumi/PFD,AamuLumi/PFD
app/webserver.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * @file Taint item.\n * @package\n */\n\n'use strict'\n\n// Imports\nconst Address = require('./address')\n\n/**\n * Private members store.\n * @private\n */\nconst privs = new WeakMap()\n\n/**\n * A taint item.\n */\nclass Taint ...
javascript
edit
0
1
unlicense
9f286d06654553ab3b394c088ad1180bcc32e7c0
jestcrows/ethtaint,jestcrows/ethtaint
src/primitives/taint.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport passport from 'passport';\nimport { Strategy } from 'passport-helsinki';\n\nimport serverConfig from './config';\n\nfunction configurePassport() {\n let helsinkiStrategy;\n helsinkiStrategy = new Strategy(\n {\n clientI...
javascript
edit
0
1
mit
5affcd42dc5d2d7b780b4581672742d0577da2b9
fastmonkeys/respa-ui
server/configurePassport.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar path = require('path');\nvar url = require('url');\nvar messages = require('./messages');\nvar ports = {};\n\nvar getSnippet = function (hostIp, socketIoPort, scriptPort) {\n return messages.scriptTags(hostIp, socketIoPort, scrip...
javascript
edit
0
5
apache-2.0
528769ac99f7983d3150e14b633442af1517ba2b
beni55/browser-sync,EdwonLim/browser-sync,Teino1978-Corp/Teino1978-Corp-browser-sync,beni55/browser-sync,syarul/browser-sync,harmoney-nikr/browser-sync,schmod/browser-sync,Plou/browser-sync,pepelsbey/browser-sync,nothiphop/browser-sync,mcanthony/browser-sync,naoyak/browser-sync,guiquanz/browser-sync,shelsonjava/browser...
lib/loadSnippet.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * Utility functions.\n */\n\nfunction serializeToJSON(arr) {\n // Convert form data to a proper json value\n var json = {};\n $.each(arr, function(_, pair){\n json[pair.name] = pair.value;\n });\n return json...
javascript
edit
0
1
mit
f24617a5beb03596eb7efa6e632d0c2be8de0a83
christabor/flask_jsondash,christabor/flask_jsondash,christabor/flask_jsondash
static/js/utils.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar Appbase = require('appbase-js');\n\nmodule.exports = {\n\tgetRequestObject: function (config, fieldName, boundingBoxCoordinates) {\n var geo_bounding_box = JSON.parse(`{\"${fieldName}\":` + JSON.stringify(boundingBoxCoordinates) ...
javascript
edit
0
2
apache-2.0
53e9eeaa77691cc8478232777bfd704da547805a
appbaseio/reactive-maps,appbaseio/reactive-maps
helper.js
rejected_duplicate
Near-duplicate of sample 71101
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { router } from '../../main';\nimport URLS from '../../urls';\n\nexport default {\n user: {\n authenticated: false\n },\n getProfile: localStorage.getItem('profile'),\n login(context, creds, redirect) {\n context.$http....
javascript
edit
0
2
mit
77c8967a7ae23aa579a598b245876556780307c8
dmurtari/mbu-frontend,dmurtari/mbu-frontend
src/services/auth/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nfunction short_hash(data, type, row, meta)\n{\n return data.substring(0,7);\n}\n\nfunction init_page()\n{\n $('#tickets').dataTable({\n \"ajax\": '/tickets/ajax/tickets.php?all=1&meta=sold',\n columns: [\n ...
javascript
edit
0
1
apache-2.0
59dbfa65c5cd71fa713ee2ca2149593f3252fd1c
BurningFlipside/Tickets,BurningFlipside/Tickets,BurningFlipside/Tickets
_admin/js/sold_tickets.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nif ( process.argv.indexOf( \"--console\" ) !== -1 ) {\n\tmodule.exports = {\n\t\tinit: function() {\n\t\t\treturn console;\n\t\t}\n\t};\n\treturn;\n}\n\nvar syslog = require( \"node-syslog\" );\n\nmodule.exports = {\n\tinit: function( n...
javascript
edit
0
1
mit
fa2632def857ec883eaf5dbc0fb9bd56cfab0981
scottgonzalez/simple-log
logger.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* eslint-env node */\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 mo...
javascript
edit
0
0
mit
c04a838041783ba2c3a4e30857f061eda8bf6140
aexmachina/ember-cli-sass,aexmachina/ember-cli-sass
testem.js
rejected_duplicate
Near-duplicate of sample 91563
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar compiler = require('./lib/compiler');\n\nmodule.exports = function(content) {\n\tthis.cacheable();\n\t\n\tvar opts = {\n\t\tsourceMap: this.sourceMap,\n\t\tsourcePath: this.resourcePath,\n\t\ttarget: this.target,\n\t\tENV_DEBUG: thi...
javascript
edit
0
3
mit
28f59f6c857a590c6abd3af2d7c9ab1814cf0090
somebee/imba,somebee/imba
loader.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar methods = ['GET', 'POST', 'HEAD', 'PUT', 'DEL', 'PATCH', 'OPTS'];\n\nvar Base = function(app) {\n\tthis.route = null;\n\tthis.setup(app);\n\tthis.routeSetup(app);\n};\n\nBase.prototype = {\n\tsetup : function(app) {\n\t\tthrow new E...
javascript
edit
0
4
mit
581e68d972080d012297915300768eb536988d01
vanng822/appskeleton,vanng822/appskeleton
api/routehandlers/base.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nconst express = require('express');\nconst MsgQueueClient = require('msgqueue-client');\n\nconst mqServerConfig = require('../common/config/mqserver.js');\nconst config = require('./config.js');\n\nconst app = express()...
javascript
edit
0
2
mit
de5b0f5fa955462018192a90be80727a83405bed
jaredscheib/tagasauris,jaredscheib/tagasauris
api-server/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nconst config = require('../config')\n\nmodule.exports = function(controller) {\n\n const apiai = require('../apiai')({token: config.apiAiToken})\n\n controller.middleware.receive.use(apiai.receive);\n controller.hear...
javascript
edit
0
1
mit
5221a17e9901c2883d90c8c2a82e918a1ae80f59
ideatosrl/mister-t
src/skills/hearAskForTimesheet.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// namespace\nvar App = App || {};\n\nApp.WebSocketState = (function () {\n \"use strict\";\n\n console.log(\"WebSocketState.create Compiling ...\");\n var fn = function (game) {\n Phaser.State.call(this, game);\n ...
javascript
edit
0
1
mit
91fdee51ac8bd249cfdd18c46c55e664e8bc8148
hookbot/multi-player,hookbot/multi-player
src/states/websocket.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nexport default {\n \"type\": \"Aggregate\",\n \"metadata\": {\"generates\": true, \"changes\": true},\n \"params\": [\n { \"name\": \"groupby\", \"type\": \"field\", \"array\": true, \"required\": true },\n { \"name\": \"fields...
javascript
edit
0
0
bsd-3-clause
99a0985739d78362c65e91e98069047734536fe6
vega/vega-dataflow
definitions/Aggregate.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nif ('serviceWorker' in navigator) {\n navigator.serviceWorker.register('offline-worker.js').then(function(registration) {\n console.log('offline worker registered');\n });\n}\n\n```\n\nApply this change: Add prompt when an updated ...
javascript
edit
0
5
apache-2.0
ae7f181036e0b94b461c982c81934380664635bb
marco-c/oghliner,mozilla/oghliner,mykmelez/oghliner,mozilla/oghliner,mykmelez/oghliner,marco-c/oghliner
app/js/offline-manager.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport FluidGeminiScrollbar from '../components/FluidGeminiScrollbar';\n\nlet scrollbarWidth = null;\n\nconst ScrollbarUtil = {\n /**\n * Taken from Gemini's source code with some edits\n * https://github.com/noeldelgado/gemini-scr...
javascript
edit
0
3
apache-2.0
1f7b6a3ed88cc61c74c877b034a1b05e51bb8c99
dcos/dcos-ui,dcos/dcos-ui,dcos/dcos-ui,dcos/dcos-ui,dcos/dcos-ui
src/js/utils/ScrollbarUtil.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*!\n * Shopping List\n * http://github.com/eheikes/shopping-list\n * License: Apache-2.0\n */\nangular.module('shoppingList', ['ngSanitize', 'ui.select', 'ng.group']).config(\n ['uiSelectConfig', function(uiSelectConfig) {\n 'use s...
javascript
edit
0
1
apache-2.0
a22470db63eadf12d68552f8ac8114ed6fb8b2c3
eheikes/shopping-list,eheikes/shopping-list
app/ShoppingListModule.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport AdminStore from 'ember-admin/stores/admin';\n\nexport function initialize(registry, app) {\n registry.register('store:admin', AdminStore);\n app.inject('route', 'admin', 'service:admin');\n app.inject('controller', 'admin', 's...
javascript
edit
0
1
mit
7bffae8cc146f26b3b84ff1a261f12e8fdef46db
dockyard/ember-admin,knownasilya/ember-admin,clairton/ember-admin,clairton/ember-admin,dockyard/ember-admin,knownasilya/ember-admin
app/initializers/admin.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar elements = document.getElementsByTagName('script')\n\nArray.prototype.forEach.call(elements, function(element) {\n if (element.type.indexOf('math/tex') != -1) {\n // Extract math markdown\n var textToRender = element.innerT...
javascript
edit
0
4
mit
188a0528856257c5cc5a495a3f445fb5395ad2b4
jboltz88/jboltz88.github.io,jboltz88/jboltz88.github.io
js/main.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport Ember from 'ember';\n\nimport OSFAgnosticAuthRouteMixin from 'ember-osf/mixins/osf-agnostic-auth-route';\nimport AnalyticsMixin from '../mixins/analytics-mixin';\n\nexport default Ember.Route.extend(AnalyticsMixin, OSFAgnosticAut...
javascript
edit
0
8
apache-2.0
1c70a9d3434c7ce5fc720e4b44be15e8a687ec22
caneruguz/ember-preprints,CenterForOpenScience/ember-preprints,caneruguz/ember-preprints,laurenrevere/ember-preprints,pattisdr/ember-preprints,pattisdr/ember-preprints,baylee-d/ember-preprints,CenterForOpenScience/ember-preprints,baylee-d/ember-preprints,laurenrevere/ember-preprints
app/routes/application.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * Created by Caleb on 9/25/2014.\n */\n(function () {\n angular.module('fc.login').config([\n '$stateProvider',\n '$urlRouterProvider',\n routeConfig\n ]);\n\n function routeConfig($stateProvider, $ur...
javascript
edit
0
1
mit
1f5aba85ef9cc049d0de0f6ff9ed8df296cc02a2
kelvinlogic/home,kelvinlogic/home
app/login/login.config.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n#!/usr/bin/env node\n\nconst cli = require('commander')\nconst pkg = require('../package')\nconst apiCall = require('./apiCall')\n\ncli.name('ur-cli')\n\ncli\n .version(pkg.version).usage('<command> <args> [options]')\n .command('crea...
javascript
edit
0
1
mit
21ba74abf9d31e3399c39b194273850689edf1e7
trolster/ur-cli,trolster/urcli,gabraganca/ur-cli
lib/cli.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar $ = require('jquery');\n\nmodule.exports = {\n\n\t$doc: $(document),\n\n\tsetupDom: function () {\n\n\t\tthis.$el = $(this.element);\n\n\t\tthis.$el.addClass(this.options.classes.originalSelect);\n\n\t\t// Setup wrapper\n\t\tthis.$w...
javascript
edit
0
1
mit
4a9885d043b48e372af8dfb8ff698a4e5c86e593
niksy/kist-selectdown,niksy/kist-selectdown
lib/dom.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar async = require('async');\nvar AWS = require('aws-sdk');\nrequire('dotenv').config();\n\nAWS.config.update({\n region: process.env.AWS_REGION\n});\n\nvar docClient = new AWS.DynamoDB.DocumentClient();\n\nmodule.exports = {\n // Pe...
javascript
edit
0
3
mit
231db974ed8eaeb476efd6722ee4d36b79932018
uzyn/taxisg,uzyn/taxisg
dynamodb.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\n// Configuring the Articles module\nangular.module('jobs').run(['Menus',\n\tfunction(Menus) {\n\t\t// Set top bar menu items\n\t\tMenus.addMenuItem('topbar', 'Jobs', 'jobs', 'dropdown', '/jobs(/create)?');\n\t\tMenus.ad...
javascript
edit
0
1
mit
1be1f9b4ccc8f4b4d7c3679ed06a45cdea497bcb
Yadnss/yadnss,Yadnss/yadnss,Yadnss/yadnss,Yadnss/yadnss
public/modules/jobs/config/jobs.client.config.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport Vue from 'vue';\nimport VueRouter from 'vue-router';\nimport VueForm from 'vue-form';\nimport { sync } from 'vuex-router-sync';\n\nimport store from './vuex/store.js';\nimport * as actions from './vuex/actions.js';\n\nimport App ...
javascript
edit
0
1
mit
f57802a240ef528b5df1ee5c1dd828fbb5aeb8fd
wkevina/feature-requests-app,wkevina/feature-requests-app,wkevina/feature-requests-app
assets/js/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// Smooth Scroll\nsmoothScroll.init({\n speed: 800,\n easing: 'easeInOutCubic',\n updateURL: false,\n offset: 125\n});\n\n// Inject data-scroll attr into footnotes\nfunction footnotesSmoothScroll() {\n var sups = document...
javascript
edit
0
2
mit
3ed9b3e428c84d100f4a405b1af4506d6ac387c7
epistrephein/Steam,epistrephein/Steam
assets/js/steam.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\npwi_form = function() {\nvar $viewerSelected = 'fancybox',\nsettings = {\n username: '<EMAIL>',\n popupPlugin: $viewerSelected,\n showPhotoDownload: true,\n showPhotoCaption: true,\n showPhot...
javascript
edit
0
1
mit
d5a817f6916dbf86235caea5ce3ae7d79c8c57ee
sjccs/cemetery-reader
js/pwi.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar findup = require('findup-sync');\nvar spawnSync = require('child_process').spawnSync;\nvar gruntPath = findup('node_modules/grunt-cli/bin/grunt', {cwd: __dirname});\n\nprocess.title = 'grunth';\n\nvar harmonyFlags =...
javascript
edit
0
1
mit
7c11d8f613fd9cdb8551f29f820bb7e474ecde9a
EE/grunth-cli
lib/cli.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*\n Add a default clickhandler so we can use hrefs\n */\nBackbone.View.prototype.defaultClickHandler = function( e ) {\n if ( e.metaKey || e.ctrlKey || e.altKey ) return;\n\n var routeTo = $(e.target).closest('a').attr('href');\n ...
javascript
edit
0
6
mit
2a3375b5dccb2f6e5f66e69259e3acc92412a738
Factlink/factlink-core,daukantas/factlink-core,Factlink/factlink-core,Factlink/factlink-core,daukantas/factlink-core,Factlink/factlink-core,daukantas/factlink-core,daukantas/factlink-core
core/app/backbone/contrib/default_click_handler.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar assert = require('assert');\nvar validate = require('../index');\n\ndescribe('JSON', function(){\n\n\tvar file = {\n\t\tname: 'task-rest_bold.json',\n\t\trelativePath: '/task-rest_bold.json'\n\t};\n\n\tit('should catch missing clo...
javascript
edit
0
2
mit
c374c5cf6931e340cc162f8fb6da2e937c10f163
Squishymedia/bids-validator,nellh/bids-validator,Squishymedia/BIDS-Validator,nellh/bids-validator,nellh/bids-validator
tests/json.spec.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\ncommand: 'echo \"nothing\"',\n\nupdateFrequency: 600000,\n\nstyle: '@import \"/stolaf-base/base.css\"',\n\nrender: function(output) {\n\treturn ''\n}\n\n```\n\nApply this change: Load css files from a list" }, { "role": "assista...
javascript
edit
null
null
mit
c1a6c498c8bebe7f58c27564eb4675a34d75d132
hawkrives/stolaf-ubersicht-widgets,hawkrives/stolaf-ubersicht-widgets,hawkrives/stolaf-ubersicht-widgets
stolaf-base/load-base-css.js
rejected_syntax
Syntax error detected by tree-sitter
false
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar configLoader = require('./config-loader');\nvar LessHint = require('./lesshint');\nvar meow = require('meow');\n\nmodule.exports = function () {\n var config;\n var lesshint = new LessHint();\n var args = m...
javascript
edit
0
3
mit
bd7bab80d37618f844b1c420c787d6c02d5e5a08
gilt/lesshint,JoshuaKGoldberg/lesshint,lesshint/lesshint,runarberg/lesshint
lib/cli.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar selection = window.getSelection();\nvar urls = [];\n\nfunction get_links(node) {\n var i;\n var child;\n var children;\n\n if (!node) {\n return;\n }\n\n children = node.childNodes;\n\n if (children === undefined || childr...
javascript
edit
0
7
apache-2.0
4153c3e86d4bb32b1f31c507cfd21616ac0381d4
ggreer/linksplosion
content_script.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\"use strict\";\n\nimport Ember from \"ember\";\nimport moment from \"moment\";\n\nconst DAYSINTOMONTH = 7;\n\nexport default Ember.Mixin.create({\n queryParams: ['month'],\n\n month: Ember.computed(function() {\n var date = momen...
javascript
edit
0
2
mit
76f536e853c84fe3ed226b756d835c3d9a8e6a91
bfcoder/vt-ht-tracker,bfcoder/vt-ht-tracker,bfcoder/vt-ht-tracker
tracker-client/app/mixins/common-date.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// @flow\nimport _ from 'lodash'\nimport program from 'commander'\n\nimport info from '../package.json'\n\nexport type Options = {\n command: ?string,\n files: Array<string>,\n format: string,\n branch: string,\n linter: string,\n ...
javascript
edit
null
null
mit
bd73417062f925ca2a3f5bbbb7ece5fc3a6acce0
relekang/lint-filter,relekang/lint-filter,relekang/lint-filter
src/cli.js
rejected_syntax
Syntax error detected by tree-sitter
false
[ { "role": "user", "content": "Here is the current file:\n```javascript\nfunction browseSuccess(r, stat, jqXHR) {\n $('#editor-panel').html(r);\n $('.igt-panel').each(function(index, elem) {\n $(elem).panel({\n title: 'Instance '+$(elem).attr('id')\n });\n });\n $('.butto...
javascript
edit
0
1
mit
68912b9ee0811190bd250a08cc695a892ec76555
xigt/yggdrasil,xigt/yggdrasil,xigt/yggdrasil
static/browser.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport {map} from 'event-stream';\nimport gulp from 'gulp';\nimport {addReleaseNotesToTag} from './helpers/github-service';\nimport {log} from 'gulp-util';\n\nconst plugins = require('gulp-load-plugins')();\n\ngulp.task('release-zip', (...
javascript
edit
0
3
mit
42bfa4ae95ebf452bf0af45496b0fe901976bebf
CanopyCloud/pivotal-ui,pivotal-cf/pivotal-ui,sjolicoeur/pivotal-ui,CanopyCloud/pivotal-ui,pivotal-cf/pivotal-ui,sjolicoeur/pivotal-ui,npm/pivotal-ui,CanopyCloud/pivotal-ui,npm/pivotal-ui,pivotal-cf/pivotal-ui,sjolicoeur/pivotal-ui,sjolicoeur/pivotal-ui,npm/pivotal-ui
tasks/release-travis.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n(function() {\n /**\n * Iterates over each link found on a Feedly page emiting its url to +callback+.\n */\n function eachFeedlyUrl(callback) {\n var link_attribute = \"data-alternate-link\";\n var links = document.querySele...
javascript
edit
0
2
mit
6329917f78b106a507a4bd8d3a37b3910f64e1ea
splattael/chrome-feedly-tabs,splattael/chrome-feedly-tabs
js/tabs.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * This example demonstrates setting up webhook\n * on the OpenShift platform.\n */\n\n\nconst TOKEN = process.env.TELEGRAM_TOKEN || 'YOUR_TELEGRAM_BOT_TOKEN';\nconst TelegramBot = require('../..');\n// See https://developers.opens...
javascript
edit
0
1
mit
455a93cacb0ca2c1ddd679e29d46a781f0d782e8
yagop/node-telegram-bot-api
examples/webhook/openshift2.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n#!/usr/bin/env node\n\nlet Server = require('../../server')\n\nlet app = new Server({\n subprotocol: '1.0.0',\n supports: '1.x'\n})\napp.nodeId = 'server:FnXaqDxY'\n\napp.on('fatal', e => console.log(`Fatal event: ${ e.message }`))\n\...
javascript
edit
0
1
mit
46d76ab0682b5a42016b98762ad770a4067b8e56
logux/logux-server
test/servers/uncatch.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// Reference : http://danialk.github.io/blog/2013/02/23/authentication-using-passportjs/\nvar CONFIG = module.exports = {};\nvar LocalStrategy = require('passport-local').Strategy;\n\nvar oauthserver = require('node-oauth2-server');\nva...
javascript
edit
0
1
mit
27651a1e39a5f19c1f467fde98d5042342521cf9
CarterTsai/APIServer,CarterTsai/APIServer
lib/config.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nwindow.openWithRiot = function(tag, opts) {\n console.log('OPEN', tag);\n riot.compile(\"tags/\" + tag + \".html\", function() {\n riot.mount(\"div#app\", tag, opts);\n });\n};\n\n/// Routes\nriot.compile(\"tags/ds-nav-layout.html...
javascript
edit
0
1
mit
0ae9669eb44d057a585e4f2554ec32c97b8d41ec
dictav/dictav.github.com,dictav/dictav.github.com,dictav/dictav.github.com
js/riot_router.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nmodule.exports = require('../StripeResource').extend({\n path: 'coupons',\n includeBasic: ['create', 'list', 'retrieve', 'del']\n});\n\n\n```\n\nApply this change: Add update method to coupon resource for metadata" ...
javascript
edit
0
0
mit
1a44ade3a8b59194a4dfbbf2e081da51749bd2e6
matthewarkin/stripe-node,tempbottle/stripe-node,fingerfoodstudios/fusebill-node,toymachiner62/stripe-node,DanielAudino/fusebill-node,stripe/stripe-node,buunguyen/stripe-node,stripe/stripe-node,djeusette/stripe-node,bendiy/stripe-node,bradcavanagh-ffs/fusebill-node
lib/resources/Coupons.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\nvar moment = require('moment');\n\n// note that month indices are zero-based\n\nmodule.exports.DATA_START_YEAR = 2012;\nmodule.exports.DATA_START_MONTH = 0;\n\nmodule.exports.DATA_END_YEAR = 2015;\nmodule.exports.DATA_END_MONTH = 8;\n...
javascript
edit
0
0
mit
156c6d8583d171270258a39805978ac190332683
lucified/lucify-refugees,lucified/lucify-refugees,lucified/lucify-refugees,lucified/lucify-refugees
src/js/model/refugee-constants.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar path = require('path');\nvar gulp = require('gulp');\nvar less = require('gulp-less');\nvar prefix = require('gulp-autoprefixer');\n\nvar config = require('../../project.config');\n\ngulp.task('build:css', 'Build CS...
javascript
edit
0
1
mit
1ae6e8a9e94b9304387713f158e2e29eedcbf7e9
baer/isThereAFuckingGame
gulp-tasks/browser/build-css.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n//Filter experiment or computation templates\n\nApplication.Filters.filter('byMediaType', function () {\n return function (items, values) {\n var matches = [];\n if (items) {\n items.forEach(function(item) {\...
javascript
edit
0
2
mit
8ec96f69f550f13e71a245ee661fd2ff1300e8ce
materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org
website/app/application/core/projects/project/files/media-type-filter.js
rejected_duplicate
Near-duplicate of sample 75335
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst functions = require('firebase-functions');\n\n// // Create and Deploy Your First Cloud Functions\n// // https://firebase.google.com/docs/functions/write-firebase-functions\n//\n// exports.helloWorld = functions.https.onRequest((re...
javascript
edit
0
0
mit
f4572eeb4238de68af10d698d98e0649e04f3fb2
RoryDuncan/Portfolio-2017,RoryDuncan/Portfolio-2017
functions/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n---\n---\n\nvar Collections = (function(window, undefined) {\n /*\n * Listing of all the collections and documents. Generated\n * automatically by Jekyll and used e.g for the auto-linking\n * feature. Don't edit this file...
javascript
edit
null
null
mit
b72a15bca3381cf05d4a814a06c213750dcde584
spyysalo/annodoc,spyysalo/annodoc
lib/local/collections.js
rejected_syntax
Syntax error detected by tree-sitter
false
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// Set up a collection to contain player information. On the server,\n// it is backed by a MongoDB collection named \"players\".\n\nPlayers = new Meteor.Collection(\"players\");\n\nif (Meteor.isClient) {\n Template.leaderboard.players ...
javascript
edit
0
3
mit
d18923d26e9419eb41067fc935ffee671dc6b722
dev-bobsong/meteor,wmkcc/meteor,jagi/meteor,jeblister/meteor,lieuwex/meteor,pjump/meteor,kencheung/meteor,Hansoft/meteor,aramk/meteor,tdamsma/meteor,kidaa/meteor,EduShareOntario/meteor,dboyliao/meteor,Puena/meteor,jeblister/meteor,ljack/meteor,esteedqueen/meteor,alphanso/meteor,udhayam/meteor,judsonbsilva/meteor,evilem...
examples/leaderboard/leaderboard.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*jshint node: true*/\n\n'use strict';\n\nmodule.exports = {\n options: {\n indent: ' '\n },\n npm: {\n src: '<%= meta.cwd %>package.json',\n dest: '<%= meta.build %>package.json',\n fields: {\n ...
javascript
edit
0
0
mit
04125bf7e3b846190bf9521d386b85d5fb40c5c8
brix/cla55
grunt/config/update_json.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react';\nimport Paper from 'material-ui/lib/paper';\n\nexport default class App extends React.Component {\n render() {\n return (\n <div style={{ width: '960px', margin: '1em auto' }}>\n <Paper zDepth=...
javascript
edit
0
1
cc0-1.0
af780d5a721eaecb830d32ba0d961ec42794eb2e
ksmithbaylor/simple-weather,ksmithbaylor/simple-weather
src/App.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\nconst pkg = require('../../package.json');\nconst Generator = require('yeoman-generator');\nconst updateNotifier = require('update-notifier');\n\nlet hasBeenNotified = false;\n\nfunction runUpdateNotifier() {\n if (hasBe...
javascript
edit
0
2
bsd-3-clause
07859637662e21db68f9a7c42c75c83bceb896c6
phovea/generator-phovea,phovea/generator-phovea,phovea/generator-phovea,phovea/generator-phovea,phovea/generator-phovea
generators/_version/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar tape = require(\"tape\"),\n jsdom = require(\"jsdom\"),\n d3_transition = require(\"d3-transition\"),\n d3_selection = require(\"d3-selection\"),\n d3_component = require(\"../\"),\n d3 = Object.assign(d3_selection, d...
javascript
edit
0
1
bsd-3-clause
6a10a21c7091974f2a16c22a5bc5ad3dca6bba78
curran/d3-component
test/exit-test.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst binding = require('bindings')('contextify');\nconst ContextifyContext = binding.ContextifyContext;\nconst ContextifyScript = binding.ContextifyScript;\n\nfunction Contextify (sandbox) {\n if (typeof sandbox != 'object') {\n ...
javascript
edit
0
2
mit
d2fc0a46764b1ac8a657cbc4db009167e9c909b0
brianmcd/contextify,brianmcd/contextify,brianmcd/contextify
lib/contextify.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react';\nimport YouTube from 'react-youtube';\n\nconst VideoInstruction = React.createClass({\n render: function() {\n const opts = {\n width: '100%' // This matches the width of the other responses\n };\...
javascript
edit
0
2
mit
8b9b4c38dde552124a21471012d0ed55314e787e
nicolasartman/chalees-min,nicolasartman/learning-prototype,nicolasartman/learning-prototype,nicolasartman/chalees-min
src/js/video-instruction.js
rejected_duplicate
Near-duplicate of sample 84257
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar SubArray = require('../../array/_sub-array-dummy-safe');\n\nmodule.exports = function (t, a) {\n\tvar arr = [1, 2, 3];\n\ta(t(arr), true, \"Array\");\n\ta(t(null), false, \"Null\");\n\ta(t(), false, \"Undefined\");\...
javascript
edit
0
2
isc
c41be39ec9f415f177504e81ba849770f3082cea
medikoo/es5-ext
test/array/is-plain-array.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nbespoke.plugins.<%= pluginNameCamelized %> = function(deck) {\n\n /*\n Interact with the deck\n https://github.com/markdalgleish/bespoke.js#deck-instances\n */\n deck.next();\n deck.prev();\n deck.slide(0);\n\n /*\n Slid...
javascript
edit
null
null
mit
ce07bb45f7fab8b3afeac4a803492e91f3b5a5c6
bespokejs/generator-bespokeplugin,mbasanta/generator-bespokeplugin,markdalgleish/generator-bespokeplugin,mbasanta/generator-bespokeplugin
app/templates/src/name.js
rejected_syntax
Syntax error detected by tree-sitter
false
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport axios from 'axios';\nimport queryString from 'query-string';\n\nexport const endpoint = axios.create({\n baseURL: 'http://localhost:5000/api/2',\n headers: {},\n // Use non-bracket array params format\n paramsSerializer: quer...
javascript
edit
0
2
mit
4dd46fe3d9e611422abaac91f011ca444cac219a
alephdata/aleph,alephdata/aleph,alephdata/aleph,alephdata/aleph,pudo/aleph,pudo/aleph,pudo/aleph,alephdata/aleph
src/api.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\n/**\n * Run package tests.\n * (C) 2015 Alex Fernández.\n */\n\n// requires\nvar testing = require('testing');\nvar Log = require('log');\n\n// globals\nvar log = new Log('info');\n\n\n/**\n * Run all module tests.\n */...
javascript
edit
0
1
mit
667c767a9070daaf7b11bc2c997fb528066d72a2
alexfernandez/inits
runTests.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*\n * This script adds cross-document messaging (postMessage) support, to allow\n * embedding one or many instances of the Tree Illustrator UI in an\n * IPython notebook. This lets us provide tree data from the surrounding\n * IPython ...
javascript
edit
0
4
bsd-2-clause
72f8219cd34696cc7c860247038a3be991fc8451
OpenTreeOfLife/tree-illustrator,OpenTreeOfLife/tree-illustrator
stylist/ipython-notebook-bridge.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n(function (exports) {\n var Controls = exports.Controls = {};\n\n Controls.attach = function (options) {\n var self = this;\n\n document.addEventListener('keypress', function (e) {\n if (String.fromCharCode(e.keyCode) == \"...
javascript
edit
0
5
mit
88126de176ab8e33309a1091efa9a0d905277af6
mmalecki/presents
js/presents/plugins/controls.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport Application from '<%= modulePrefix %>/app';\nimport config from '<%= modulePrefix %>/config/environment';\nimport { setApplication } from '@ember/test-helpers';\nimport { start } from 'ember-qunit';\n\nsetApplication(Application....
javascript
edit
0
0
mit
2ece79d6ada478f149a8e5f09eddef3271f3149a
ember-cli/ember-cli,buschtoens/ember-cli,buschtoens/ember-cli,thoov/ember-cli,asakusuma/ember-cli,raycohen/ember-cli,ember-cli/ember-cli,thoov/ember-cli,raycohen/ember-cli,kategengler/ember-cli,thoov/ember-cli,elwayman02/ember-cli,balinterdi/ember-cli,elwayman02/ember-cli,kategengler/ember-cli,ember-cli/ember-cli,asaku...
blueprints/app/files/tests/test-helper.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport express from 'express';\nimport logger from 'morgan';\nimport bodyParser from 'body-parser';\n\nimport routes from './routes';\n\nconst app = express();\nconst port = process.env.PORT || 3001;\n\napp.use(logger('dev'));\napp.use(...
javascript
edit
0
1
apache-2.0
3375f51c1e947de3820fdbd3a26848114a9db976
larrystone/BC-26-More-Recipes,larrystone/BC-26-More-Recipes
server/app.js
rejected_duplicate
Near-duplicate of sample 89312
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = class KiteError extends Error {\n constructor(type, data, content) {\n super(type);\n this.name = this.constructor.name;\n this.message = type;\n this.type = type;\n this.data = data;\n this.content =...
javascript
edit
0
2
bsd-3-clause
42bffde734e0b547068f77c04a736a539dafa894
kiteco/kite-installer
lib/kite-error.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst updateCode = newCode => {\n return { type: 'UPDATE_CODE', newCode };\n};\n\nconst swapCode = () => {\n return { type: 'TOGGLE_TREE_TYPE' };\n};\n\nconst darken = () => {\n return { type: 'DARKEN_THEME' };\n};\n\nconst lighten =...
javascript
edit
0
1
mit
aee26ca3bd8da1be1f2582aba65364ae13f0416d
ivtpz/brancher,ivtpz/brancher
app/actions/userCodeActions.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// A PhantomJS sript that simply opens the web page passed as the command line parameter\nvar page = require('webpage').create();\npage.open(phantom.args[0], function (status) {\n});\n\n```\n\nApply this change: Print PhantomJS errors a...
javascript
edit
0
3
mit
a862cd5744c81cbd784e253b0cbf873f40619b2d
ekryski/launchpad,brettpostin/launchpad,ekryski/launchpad,brettpostin/launchpad
resources/phantom.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nclass ActionRegistry {\n reducers = {}\n\n register(actionType, reducer, actionCreator = () => ({})) {\n this.reducers[actionType] = reducer\n return (...args) => Object.assign({type: actionType}, actionCreator(...ar...
javascript
edit
0
1
mit
d92799eb4af525ea50c96d109c8d5740153421bd
openforis/sepal,openforis/sepal,openforis/sepal,openforis/sepal,openforis/sepal,openforis/sepal
modules/gui-react/frontend/src/action-registry.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule('Placed Symbol');\n\ntest('placedSymbol bounds', function() {\n\tvar doc = new Document();\n\tvar path = new Path.Circle([50, 50], 50);\n\tvar symbol = new Symbol(path);\n\tvar placedSymbol = new PlacedSymbol(symbol);\n\t\n\t// T...
javascript
edit
0
1
mit
a7ec0ef269874b3cf84aea74ed66bc0f64fdb703
luisbrito/paper.js,fredoche/paper.js,lehni/paper.js,ClaireRutkoske/paper.js,Olegas/paper.js,proofme/paper.js,legendvijay/paper.js,ClaireRutkoske/paper.js,NHQ/paper,legendvijay/paper.js,byte-foundry/paper.js,proofme/paper.js,baiyanghese/paper.js,iconexperience/paper.js,baiyanghese/paper.js,Olegas/paper.js,superjudge/pap...
test/tests/PlacedSymbol.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n(function() {\n module(\"R.rPartial\");\n\n var rPartial = require('eigensheep/r_partial')['default'];\n var multiply = function(a, b) { return a * b; };\n var greet = function(salutation, title, firstName, lastName) {\n return s...
javascript
edit
0
1
mit
e2f49e17b1095835189f10c2c635cdb7c0a54a6a
markprzepiora/eigensheep,markprzepiora/eigensheep,markprzepiora/eigensheep
test/eigensheep/r_partial_test.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* global require, module */\n\nvar EmberApp = require('ember-cli/lib/broccoli/ember-app');\n\nmodule.exports = function (defaults) {\n var app = new EmberApp(defaults, {\n outputPaths: {\n app: {\n html: 'my-app.html',\...
javascript
edit
0
1
mit
39d35f6b144e08c098a8912e01c044ef02ff1bdf
Turbo87/ember-cli,cibernox/ember-cli,nathanhammond/ember-cli,raycohen/ember-cli,romulomachado/ember-cli,xtian/ember-cli,sivakumar-kailasam/ember-cli,jrjohnson/ember-cli,trentmwillis/ember-cli,kanongil/ember-cli,patocallaghan/ember-cli,akatov/ember-cli,elwayman02/ember-cli,johanneswuerbach/ember-cli,jrjohnson/ember-cli,...
tests/fixtures/brocfile-tests/custom-output-paths/ember-cli-build.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar _ = require('lodash');\nvar RSVP = require('rsvp');\nvar resolveProjectPath = require('../../resolveProjectPath');\nvar fs = require('fs');\nvar utils = require('../../utils');\n\nmodule.exports = function(context, ...
javascript
edit
0
8
mit
143322954e02c12190d0aa96295fe788f9d06f59
firebase/firebase-tools,firebase/firebase-tools,lguzzon/firebase-tools,firebase/firebase-tools,firebase/firebase-tools,firebase/firebase-tools,lguzzon/firebase-tools
lib/deploy/functions/prepare.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport is from 'is_js';\nimport appState from '../core/state';\nimport { AT, COLON, DOLLAR } from '../constants';\n\nimport logout from './logout';\n\nconst myCommands = [\n logout,\n];\n\nfunction createNewLine() {\n const historyCom...
javascript
edit
0
6
mit
b3b68679883f9319b5c23977b792b5e8d8901b16
guokeke/myblog
src/commands/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\ndescribe('basic mark in large documents', function() {\n var $ctx, err, start, end, diff;\n beforeEach(function(done) {\n loadFixtures('basic/large-document.html');\n\n $ctx = $('.basic-large-document');\n err ...
javascript
edit
0
3
mit
3fa51c50d5773e6c7ff31f97f5fd83de9b294c72
julmot/jquery.mark,julmot/jmHighlight,julmot/jquery.mark,julmot/mark.js,julmot/jmHighlight,julmot/mark.js
test/specs/basic/large-document.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\niD.svg.Areas = function(projection) {\n return function drawAreas(surface, graph, entities, filter) {\n var areas = [];\n\n for (var i = 0; i < entities.length; i++) {\n var entity = entities[i];\n ...
javascript
edit
0
4
isc
62e8d4ed640f85293640a091dc314d9a28fdddce
energiekollektiv/openmod.sh-id,kartta-labs/iD,morray/iD,1ec5/iD,mapmeld/iD,kartta-labs/iD,tbicr/iD,zbycz/iD,mapmeld/iD,bagage/iD,openstreetmap/iD,AndreasHae/iD,kepta/iD,kartta-labs/iD,digidem/iD,edpop/iD,edpop/iD,mapmeld/iD,bagage/iD,ngageoint/hootenanny-ui,edpop/iD,ngageoint/hootenanny-ui,AndreasHae/iD,kepta/iD,energi...
js/id/svg/areas.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nexport default {\n host: process.env.HOST || 'localhost',\n port: process.env.PORT || 8080,\n apiUrl: `http://${process.env.API_URL || 'step-up-api.dev'}`,\n app: {\n name: 'StepUp',\n head: {\n title: 'StepUp',...
javascript
edit
0
0
mit
bb38439d4aaf473087fe03ebd22377a83687a14d
elstgav/stair-climber,elstgav/stair-climber,elstgav/step-up
config.js
accepted
null
true