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/**\n * The MIT License\n *\n * Copyright (c) 2010 Steven G. Brown\n *\n * Permission is hereby granted, free of charge, to any person\n * obtaining a copy of this software and associated documentation\n * files (the \"Software\"), to d...
javascript
edit
0
2
mit
67d802402d593d7d01f11a60b8bdc43ce1ad48b4
StevenGBrown/javadoc-search-frame,StevenGBrown/javadoc-search-frame
src/googlechrome/lib/Messages.js
accepted
null
true
[ { "role": "user", "content": "Write javascript code for the following: Add initial tests for CI" }, { "role": "assistant", "content": "/**\n * Created by Dmytro on 4/11/2016.\n */\n\ndescribe('Initial test for CI', function() {\n\n it('should pass', function() {\n expect(true).toBe(tru...
javascript
new_file
0
1
mit
6e3f715bc54d9edcfed06c24bffacdbde66a3b3d
dverbovyi/angular-heremaps,dverbovyi/angular-heremaps
tests/heremaps.directive.spec.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\ndefine([\n 'extensions/views/graph/xaxis'\n],\nfunction (XAxis) {\n var ConversionXAxis = XAxis.extend({\n useEllipses: true,\n tickValues: function () {\n return _.range(this.collection.at(0).get('values').length);\n },...
javascript
edit
0
1
mit
9fb7b57e184af532859ffda5fa696c5c8cc040ba
alphagov/spotlight,tijmenb/spotlight,alphagov/spotlight,keithiopia/spotlight,alphagov/spotlight,tijmenb/spotlight,tijmenb/spotlight,keithiopia/spotlight,keithiopia/spotlight
app/common/views/visualisations/conversion-graph/xaxis.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* eslint-disable no-multi-spaces */\n\nfunction test () {\n var runAllTests = require('../testers/loopOverAllTestSets.js');\n var testName = 'identify';\n var path = require('path');\n var mnt = '/mnt';\n if (process.pla...
javascript
edit
0
1
mit
f660ff2f1aedf0a3d152210c1e4b475cc5945c7c
FLIF-hub/node-flif
src/information/identify.test.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = function(grunt) {\n\n\tgrunt.initConfig({\n\t\tcopy: {\n\t\t\tmain: {\n\t\t\t\tsrc: [\n\t\t\t\t\t'languages/*',\n\t\t\t\t\t'advanced-post-excerpt.php',\n\t\t\t\t\t'LICENSE.md',\n\t\t\t\t\t'readme.txt'\n\t\t\t\t],\n\t\t\...
javascript
edit
0
1
mit
f86350c0720f24862b7dd3023d80fa0db20c079b
stevegrunwell/advanced-post-excerpt,stevegrunwell/advanced-post-excerpt,stevegrunwell/advanced-post-excerpt
Gruntfile.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\nmodule.exports = function(grunt) {\n\n // Project configuration.\n grunt.initConfig({\n dox: {\n options: {\n title: \"Rebelizer API Docs\"\n },\n files: {\n src: ['lib/**/*.js'],\n dest: 'do...
javascript
edit
0
1
mit
4fa4728310735feb1b2bad644ec888d00f79a055
Rebelizer/rebelizer
Gruntfile.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n$(document).ready(function() {\n\n hide_frequency();\n $(\"#id_repeats_0\").click(function() {\n\t\tif ($(\"#id_count\").val() > 1) {\n\t\t\tshow_frequency();\n\t\t} else {\n\t\t\thide_frequency();\n\t\t}\n\t});\n $(\"#id_count...
javascript
edit
0
2
mit
9ab0c4cc0ec33672e269522e749cf3509b358912
thrive-refugee/thrive-refugee,thrive-refugee/thrive-refugee,thrive-refugee/thrive-refugee
refugee_manager/static/js/recurring_form.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\"use strict\";\n\nvar React = require('react');\n\nmodule.exports = React.createClass({\n\n displayName: 'Home',\n\n getInitialState: function(){\n return {};//getStateFromStores();\n },\n \n render: function() {\...
javascript
edit
0
1
mit
d728e89402b345c6f4ce141aa0db47e4a7afe3fc
SergeBredin/6element,anthill/6elementApp,SergeBredin/6element,anthill/6elementApp,SergeBredin/6element
src/Components/Home.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* Copyright 2015-2016 Teeming Society. Licensed under the Apache License, Version 2.0 (the \"License\"); DreemGL is a collaboration between Teeming Society & Samsung Electronics, sponsored by Samsung and others.\n You may not use this ...
javascript
edit
0
3
apache-2.0
3fa9aed3c398061e4f69223d707246adeb765fdd
teem2/dreemgl,teem2/dreemgl,teem2/dreemgl,dreemproject/dreemgl,dreemproject/dreemgl,dreemproject/dreemgl,teem2/dreemgl,dreemproject/dreemgl,teem2/dreemgl,dreemproject/dreemgl
test/dalitests/images.js
rejected_duplicate
Near-duplicate of sample 92172
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * Created by ChengFuLin on 2015/6/10.\n */\nvar factoryAnalyzedCFG = require('../../lib/dujs').factoryAnalyzedCFG,\n should = require('should');\n\ndescribe('AnalyzedCFGFactory', function () {\n \"use strict\";\n describe...
javascript
edit
0
1
mit
786b682f4e822dc98391d3301ffdaf76a6335917
chengfulin/dujs,chengfulin/dujs
tests/dujs/analyzedcfgfactory.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\n$(function () {\n // Handler for .ready() called.\n $('[data-scrollToLink]').each(function (i, l) {\n var $link = $(l);\n $link.on('click', function () {\n $('body').scrollTo('#' + $link.a...
javascript
edit
0
1
apache-2.0
affe0ae35c920a377019c93078b1aa648c4d4f77
tdebarochez/website,tdebarochez/website
app/scripts/scripts.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// buffer-install-check.js\n// (c) 2013 Buffer\n// Adds an element to our app page that we can use to check if the browser has our extension installed.\n\nvar bufferMarkOurSite = function (version) {\n\tif (window.top !== window) return...
javascript
edit
0
4
mit
79e98c1a522f3ea78cc0b8271554a34f560093e0
bufferapp/buffer-extension-shared,vijayrawatsan/buffer-extension-shared,vijayrawatsan/buffer-extension-shared,bufferapp/buffer-extension-shared
buffer-install-check.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst HASH = '#'.charCodeAt(0);\nconst DOT = '.'.charCodeAt(0);\n\nexport const parseQuery = (query) => {\n let tag = null;\n let id = null;\n let className = null;\n let mode = 0;\n let buffer = '';\n\n for (let i = 0; i <= query...
javascript
edit
0
11
mit
22810fcc16719a913c3a3f4e8881b77410b56229
pakastin/redom,tomerigal/redom,redom/redom
src/parse-query.js
rejected_complexity
Cyclomatic complexity too high: 11
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { observable, action } from 'mobx';\n\nclass ReservedTokenStore {\n\n @observable tokens;\n\n constructor(tokens = []) {\n this.tokens = tokens;\n }\n\n @action addToken = (token) => {\n const currentToken = this.tokens...
javascript
edit
0
4
mit
d5fff96d1cdcf20b60d1271f9af862ea6edb807c
oraclesorg/ico-wizard,oraclesorg/ico-wizard,oraclesorg/ico-wizard
src/stores/ReservedTokenStore.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\nvar _ = require('lodash');\nvar P = require('bluebird');\nvar humps = require('humps');\nvar Schemas = require('../generators/schemas');\n\nfunction ResourceDeserializer(model, params) {\n var schema = Schemas.schemas[mo...
javascript
edit
0
4
mit
716b6464432885a45377ac89aa1a68a38817c5a6
SeyZ/forest-express-mongoose
deserializers/resource.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar Generator = module.exports = function () {\n\tvar cb = this.async();\n\n\tthis.prompt([{\n\t\tname: 'path',\n\t\tmessage: 'Where would you like to generate it?',\n\t\tdefault: 'css/pure'\n\t}], function (err, props)...
javascript
edit
0
1
mit
b23f37f074372598ecbe35aa53501afd4860a175
sindresorhus/generator-pure
app/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = function(grunt) {\n \n // Project configuration.\n grunt.initConfig({\n pkg: grunt.file.readJSON('package.json'),\n concat: {\n dist: {\n src: ['src/itemsimple.js', 'src/...
javascript
edit
0
1
mit
1ca611efe84aab7712ce7c487df1dd9b29306ecc
Arnooo/sosimplist,Arnooo/sosimplist
Gruntfile.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport baseConfig from './webpack.local.config.js';\n\n\nmodule.exports = (opts) => {\n\n let config = baseConfig(opts);\n\n return {\n ...config,\n devtool: 'source-map',\n output: {\n ...config.output,\n publicPat...
javascript
edit
0
1
mit
aa06c8bb3dbdd88b03b862d6a3443f408fd9a647
mcallistersean/b2-issue-tracker,mcallistersean/b2-issue-tracker,mcallistersean/b2-issue-tracker
frontend/config/webpack.local.hmr.config.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { action, observable, computed } from 'mobx'\n\n\n\nclass SearchDomain {\n\n @observable\n searchText = ''\n\n constructor(items = [], retrievers) {\n this.items = items\n this.retrievers = retrievers\n }\n\n @action\n...
javascript
edit
0
2
mit
afc1ee9d5b2b50657c435b595a88698ea2deb6a1
mindhivenz/mui-components
src/documents/SearchDomain.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst path = require('path');\nconst webpack = require('webpack');\nconst ExtractTextPlugin = require(\"extract-text-webpack-plugin\");\nconst CopyWebpackPlugin = require('copy-webpack-plugin');\nconst HtmlWebpackPlugin = require('html-...
javascript
edit
0
0
mit
e582e122d11b33e6e9f39ca76ce0e978a22361ab
hejianxian/framework7-webpack-demo,Alex-fun/framework7-webpack-demo,Alex-fun/framework7-webpack-demo,hejianxian/framework7-webpack-demo
build/webpack.config.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// See https://docusaurus.io/docs/site-config for all the possible\n// site configuration options.\n\nconst siteConfig = {\n title: 'Coursier',\n tagline: 'Pure Scala Artifact Fetching',\n\n // wiped when relativizing stuff\n url: '...
javascript
edit
0
0
apache-2.0
8c75e34915a522a0e1c85e3565c822d48920c73e
alexarchambault/coursier,coursier/coursier,coursier/coursier,alexarchambault/coursier,alexarchambault/coursier,coursier/coursier,coursier/coursier,alexarchambault/coursier
doc/website/siteConfig.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n(function() {\n \"use strict\";\n GOVUK.Tracker.load();\n var cookieDomain = (document.domain === 'www.beta.digitalmarketplace.service.gov.uk') ? '.digitalmarketplace.service.gov.uk' : document.domain;\n var property = (document.dom...
javascript
edit
0
3
mit
3c9fdc75cb44c39eb1c211bd4bf1e6071be00fd7
alphagov/digitalmarketplace-supplier-frontend,alphagov/digitalmarketplace-supplier-frontend,alphagov/digitalmarketplace-supplier-frontend,alphagov/digitalmarketplace-supplier-frontend
app/assets/javascripts/_analytics.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport Ember from 'ember';\nimport Config from 'ember-routable-modal/configuration';\n\nexport default Ember.Service.extend({\n routing: Ember.inject.service('-routing'),\n routeName: null,\n activeListener: function() {\n ...
javascript
edit
0
3
mit
a1ce5d8f0497203a3aedcba98ae66a393eed872f
dbbk/ember-routable-modal,dbbk/ember-routable-modal
app/services/current-routed-modal.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React, { PropTypes } from 'react';\nimport Immutable from 'immutable';\nimport { Table } from 'react-bootstrap';\nimport { AUTHENTICATED_USER } from '../../../utils/Consts/UserRoleConsts';\nimport styles from '../styles.module.cs...
javascript
edit
0
2
apache-2.0
85f0423d682a414d0d5fbedd8b2134386b12feeb
dataloom/gallery,kryptnostic/gallery,kryptnostic/gallery,dataloom/gallery
src/containers/permissionssummary/components/RolePermissionsTable.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\nfunction createModel(resource) {\n\n // Dynamically create constructor for model\n // TODO: Type checking + required vs non-required\n var _createModel = function(obj) {\n obj = obj || {};\n for (var prop in resource.structur...
javascript
edit
0
4
mit
f0be4b34bb5fb68378bf83910fbf6d7247f4333e
ganemone/reflux-rest
js/createModel.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react';\nimport update from 'immutability-helper';\nimport * as firebase from 'firebase';\nimport { Field } from '../Field';\nimport { notifications } from '../../service/notifications';\nimport './sections.css';\n\nc...
javascript
edit
0
1
apache-2.0
532307e2b3e4405c284c1cdf7f19751e2c666c9b
nahody/biografia,nahody/biografia
src/components/Settings/Sections.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React, { Component, PropTypes } from 'react';\n\nclass AddActivityForm extends Component {\n\n createActivity(e) {\n e.preventDefault();\n const activity = {\n description: this.description.value,\n }\n\n this....
javascript
edit
0
1
mit
ae946274170ee70154c3953fdabae6270777b709
mknudsen01/today,mknudsen01/today
src/components/AddActivityForm.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react'\nimport ClubApplicationForm from 'components/apply/ClubApplicationForm'\n\nexport default props => (\n <ClubApplicationForm params={props.application} disableAutosave />\n)\n\n```\n\nApply this change: Include...
javascript
edit
0
1
mit
22b046ceabda5d377545d5b695cfeb497ca8622a
hackclub/website,hackclub/website,hackclub/website
src/components/admin/Information.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\njsio('from shared.javascript import Class')\n\nexports = Class(function(){\n\t\n\tthis.init = function() {\n\t\tthis._pool = {}\n\t\tthis._counts = {}\n\t\tthis._uniqueId = 0\n\t}\n\t\n\tthis.add = function(name, item) {\n\t\tif (!this....
javascript
edit
0
2
mit
438f6d6e3134e33b1df0576b7a344c399cc76423
marcuswestin/fin
js/shared/Pool.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\nwindow._ = require('lodash');\n\n/**\n * We'll load jQuery and the Bootstrap jQuery plugin which provides support\n * for JavaScript based Bootstrap features such as modals and tabs. This\n * code may be modified to fit the specific n...
javascript
edit
0
0
mit
f2981650a1bba7bfb5ebdb39110b5cb3c66bdea0
hackel/laravel,remxcode/laravel-base,orckid-lab/dashboard,slimkit/thinksns-plus,cbnuke/FilesCollection,zeropingheroes/lanyard,slimkit/thinksns-plus,zhiyicx/thinksns-plus,orckid-lab/dashboard,hackel/laravel,zhiyicx/thinksns-plus,hackel/laravel,zeropingheroes/lanyard,remxcode/laravel-base,zeropingheroes/lanyard,tinywitch...
resources/assets/js/bootstrap.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nvar RNAudioPlayer = require('NativeModules').RNAudioPlayer;\n\nvar AudioPlayer = {\n play(fileName: string) {\n RNAudioPlayer.play(fileName);\n }\n};\n\nmodule.exports = AudioPlayer;\n\n```\n\nApply this change: FI...
javascript
edit
null
null
mit
0ae2bef6955ac0d8cae57bbd6b87c042610f4f20
andreaskeller/react-native-audioplayer,andreaskeller/react-native-audioplayer,BiOZed/react-native-audioplayer,BiOZed/react-native-audioplayer
AudioPlayer.js
rejected_syntax
Syntax error detected by tree-sitter
false
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = {\n inputStyle: {\n \"border\": `1px solid transparent`,\n \"borderRadius\": `1px`,\n \"boxShadow\": `0 2px 6px rgba(0, 0, 0, 0.3)`,\n \"boxSizing\": `border-box`,\n \"MozBoxSizing\...
javascript
edit
0
0
apache-2.0
add4aa5794aa3e1f5716f5384361b7d0ca0b2fbb
appbaseio/reactive-maps,appbaseio/reactive-maps
app/Style.js
rejected_duplicate
Near-duplicate of sample 77962
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use babel';\n\nimport DependenciesView from '../views/DependenciesView';\nimport getDependencies from '../yarn/get-dependencies';\nimport yarnExec from '../yarn/exec';\nimport reportError from '../report-error';\n\nexport default async...
javascript
edit
0
2
mit
e51708d963cde686b4e06fc3e19c316e629295dd
cbovis/atom-yarn
lib/actions/remove-package.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar amqp = require('amqplib');\n\nvar amqpUrl, amqpConnection, intervalID;\n\nfunction connect(_amqpUrl) {\n amqpUrl = amqpUrl || _amqpUrl || process.env.AMQP_URL || 'amqp://localhost';\n\n return amqp.connect(amqpUrl)\n .then(functi...
javascript
edit
0
4
mit
7c9d5c3258256f6e2f7f96fc787d61928ce8e40b
dial-once/node-bunnymq
lib/amqp-layer.js
rejected_duplicate
Near-duplicate of sample 74835
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar async = require('async')\nvar RSVP = require('rsvp')\n\nvar transformers = require('../transformers')\nvar Component = require('../component').Component\n\n\nexports.CompilerCollection = CompilerCollection\nCompilerCollection.protot...
javascript
edit
0
2
mit
3468980b7c5656d5ff9bae7f7f78c8f3889a32d4
gabesoft/broccoli,osxi/broccoli,gabesoft/broccoli,rwjblue/broccoli,ixisystems/broccoli,ixisystems/broccoli,broccolijs/broccoli,gabesoft/broccoli,osxi/broccoli,ember-cli/broccoli,ember-cli/broccoli,jnicklas/broccoli,osxi/broccoli,ember-cli/broccoli,broccolijs/broccoli,broccolijs/broccoli,broccolijs/broccoli
lib/transformers/compilers.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar inherits = require('util').inherits;\nvar Readable = require('stream').Readable;\n\nfunction ReadableProxy(stream, options, nil) {\n Readable.call(this, options);\n\n this._source = stream;\n this._is_reading = false;\n ...
javascript
edit
0
4
apache-2.0
196d84965d692efb82b2126f3ddf1f54543364a3
vqvu/highland,caolan/highland,vqvu/highland,caolan/highland
lib/readableProxy.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React, { PropTypes, Component } from 'react'\nimport moment from 'moment'\n\nimport eventActions from '../actions/eventActionCreators'\n\nconst TIME_INIT = moment('2190-07-02').utc()\nconst DELAY = 1000\n\nclass Time extends Comp...
javascript
edit
0
2
mit
8482d1e8c96e851751ff76e3561cb731f1ed9209
albertoblaz/lord-commander,albertoblaz/lord-commander
src/components/Time.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst axios = require('axios')\n\nconst isOnline = async (req, res) => {\n try {\n const {status} = await axios.get('https://myanimelist.net')\n\n res.status(status === 200 ? 200 : 204).send()\n } catch (e) {\n res.status(204...
javascript
edit
0
2
mit
8d4fe2a18c02c24549c4bd199654a549f6a9e9a1
Kylart/KawAnime,Kylart/KawAnime,Kylart/KawAnime
server/env/isOnline.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nHandlebars.registerHelper('session', function(input) {\n \"use strict\";\n return Session.get(input);\n});\n\nvar createAlert = function (level) {\n\t\"use strict\";\n\tHandlebars.registerHelper(level, function(title, msg) {\n\t\tvar ...
javascript
edit
0
1
mit
90ec22f8557aedd4caf678000546d96b816d0c50
rrevanth/news,rrevanth/news
client/layout/layout.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nconst Promise = require('promise');\n\n/** Execute a batch of mutations\n * @param {Array<{mutation: string, params: Array<string|number|map}>} mutations\n * @returns {Promise}\n */\nfunction executeBatchMutations(mutat...
javascript
edit
0
1
mit
3e73b644466cad6007e63156626adc0e4dbc1036
CatalystCode/project-fortis-services,CatalystCode/project-fortis-services
src/clients/cassandra/CassandraConnector.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport {theInv} from './options';\n\nexport default function decorate() {\n if (theInv.folders) {\n theInv.folders['-1'] = 'Main';\n }\n // Hide composed potions until Zorg fixes the feed\n theInv.items =\n theInv.items.filter...
javascript
edit
0
2
mit
714bab3e2b2841a2ba2bdcf08cb49539684abf84
fallenswordhelper/fallenswordhelper,fallenswordhelper/fallenswordhelper
src/modules/inventory/decorate.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// ==UserScript==\n// @name Laracasts - Full Width Video\n// @namespace http://tampermonkey.net/\n// @version 1.0\n// @description try to take over the world!\n// @author You\n// @match https://laracasts.co...
javascript
edit
0
1
mit
7d022d3a54c8bbe201f85523bf02725aafec2e1a
aihowes/userscripts
laracasts/fullwidthvideo.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n( function () {\n\n\t/**\n\t * Image Little Planet\n\t * @param {string} source \t\t- URL for the image source\n\t * @param {number} [size=10000] - Size of plane geometry\n\t * @param {number} [ratio=0.5] - Ratio of plane geometry's he...
javascript
edit
0
1
mit
a344e4d118737b10e83815cfcb52f01e3a01c596
pchen66/panolens.js,pchen66/panolens.js
src/panorama/ImageLittlePlanet.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { connect } from 'react-redux';\nimport Profile from '../components/Profile.jsx';\nimport { completeUpdate } from '../actions/index.js';\nimport request from 'then-request';\n\nconst mapStateToProps = (state) => ({\n profile: st...
javascript
edit
0
2
mit
a1ff311ae1606a5b7f935c6d427e83e34b9a457d
VictoriousResistance/iDioma,VictoriousResistance/iDioma
client/sections/profile/containers/Profile.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react';\nimport Layout from './layout';\n\nconst Introduction = () => (\n <p>\n Depcheck looks at your project files and scans your code to find any unused dependencies. Get rid of useless dependencies, and ship c...
javascript
edit
0
2
mit
f422944a6d4cccda45b5ceb9ffc4a10ac70c4528
depcheck/depcheck-www,lijunle/depcheck-web,depcheck/depcheck-www,lijunle/depcheck-web
src/views/home.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* This file is excluded from coverage because the intrumented code\n * translates \"self\" which gives a reference error.\n */\n\n/* istanbul ignore next */\n\nexport function workerCode() {\n self.document = {}; // Workaround for \...
javascript
edit
0
2
bsd-3-clause
3075f1e0a1714ab7b5961ca96f385792f7fdf96b
magjac/d3-graphviz
src/workerCode.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\nrequirejs.config({\n\tpaths: {\n\t\t'jquery': './lib/components/jquery/dist/jquery.min'\n\t}\n});\n\nrequire( [ 'src/graph' ] , function( Graph ) {\n\n\tvar functions = [\n\nfunction( domGraph ) {\n\n\tvar graph = new Graph( domGraph ...
javascript
edit
0
2
mit
a55132cb95544d1ed17fc3b037f4d6e55d04b2c4
andcastillo/graph,andcastillo/graph,NPellet/jsGraph,NPellet/jsGraph
init.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react'\n\nexport default ({ confirmation, which_text, which_delete, reset }) =>\n <div>\n <p><b>Would you like to revoke your Gift Aid declaration?</b></p>\n <button onClick={which_delete()} className={confirma...
javascript
edit
0
1
mit
afc135844f90d365d2a2de166adbe8a971a49df6
foundersandcoders/sail-back,foundersandcoders/sail-back
src/user/components/my_details/gift_aid_buttons.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nmodule.exports = Cmds.addCommand({\n cmds: [';unban ', ';remban '],\n\n requires: {\n guild: true,\n loud: false,\n },\n\n desc: 'Unban a user from the guild',\n\n args: '([user_resolvable])',\n\n example...
javascript
edit
0
2
mit
1bc375ac5c29cfc378a9a4aecb0ef003e2e02aee
Vaeb/VaeBot
commands/staff/UnBan.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nlet attachedTabs = {};\nlet textContentArr;\n// Called when the user clicks on the browser action.\nchrome.browserAction.onClicked.addListener(function (tab) {\n let tabId = tab.id;\n\n // https://developer.chrome.com/extensions/conte...
javascript
edit
0
4
isc
b8606372a97839279f93c894ed30f06751d00a14
mrv1k/bracketless,mrv1k/bracketless
core/src/bg/background.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * Moovie: an advanced HTML5 video player for MooTools.\n * @copyright 2010 Colin Aarts\n * @license MIT\n */\nimport { WebSRT } from './WebSRT.js';\nimport { WebVTT } from 'vtt.js';\n\n/**\n * Loads and parses the track based on t...
javascript
edit
0
3
mit
b04dc9e6d7039179611a00c8d07e08dfd81cf9bf
Moovie/Moovie
src/js/track/Loader.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/*jshint node:true*/\nmodule.exports = {\n scenarios: [\n {\n name: 'ember-lts-2.8',\n bower: {\n dependencies: {\n 'ember': 'components/ember#lts-2-8'\n },\n resolutions: {\n 'ember'...
javascript
edit
0
0
mit
88028d7fcb26eec2088889a2becc0cb19c39b28a
nypublicradio/nypr-account-settings,nypublicradio/nypr-account-settings
config/ember-try.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\ndescribe('validator.presence', function() {\n var presence = validate.validators.presence;\n\n it(\"doesn't allow empty values\", function() {\n expect(presence('', {})).toBeDefined();\n expect(presence(' ', {})).toBeDefined();...
javascript
edit
0
1
mit
7d48a9d5008d8a048a6af081301f973bc26607c6
Renji/validate.js,jinjiang2009/validate.js,tilleps/validate.js,tuvistavie/validate.js,geminiyellow/validate.js,Renji/validate.js,tilleps/validate.js,jinjiang2009/validate.js,ansman/validate.js,danghongthanh/validate.js,linde12/validate.js,geminiyellow/validate.js,tuvistavie/validate.js,andban/validate.js,andban/validat...
spec/validators/presence-spec.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst selectors = require('../../../../selectors')\nconst userActions = require('../../support/user-actions')\n\ndescribe('Contacts', () => {\n const data = {\n name: 'NewAddress',\n lastName: 'Contact',\n jobTitle: 'Coffee ma...
javascript
edit
0
1
mit
6135d4124da92bf21b9a10d829dd0196e2af8985
uktrade/data-hub-frontend,uktrade/data-hub-fe-beta2,uktrade/data-hub-frontend,uktrade/data-hub-fe-beta2,uktrade/data-hub-frontend
test/end-to-end/cypress/specs/DIT/contacts-spec.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { greekLetters, randomFromList } from \"../constants\";\n\nexport default (_, { name, stations, displayName = name }) => {\n // Find the station with the probe construction\n const station = stations.find(s =>\n s.cards.find...
javascript
edit
0
2
apache-2.0
a526194b61a921c76c762a82044a2fa74ac8d456
Thorium-Sim/thorium,Thorium-Sim/thorium,Thorium-Sim/thorium,Thorium-Sim/thorium
server/classes/generic/damageReports/functions/computerCore.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport { GoogleAnalyticsBackwardsCompability } from './src/GoogleAnalyticsBackwardsCompability';\nimport { GoogleAnalyticsTracker } from './src/GoogleAnalyticsTracker';\nimport { GoogleAnalyticsSettings } from './src/GoogleAnalyticsSett...
javascript
edit
0
0
mit
a1aee55ea8a0ce9b143ff40df4135a3f2d1008c2
mmiani/react-native-google-analytics-bridge,mmiani/react-native-google-analytics-bridge,idehub/react-native-google-analytics-bridge,mmiani/react-native-google-analytics-bridge,idehub/react-native-google-analytics-bridge,mmiani/react-native-google-analytics-bridge,idehub/react-native-google-analytics-bridge,idehub/react...
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nexport default {\n name: 'ArticleNav',\n configure (config) {\n config.addLabel('mode', 'Mode')\n config.addViewMode({\n name: 'open-manuscript',\n viewName: 'manuscript',\n commandGroup: 'switch-view',\n ico...
javascript
edit
0
1
mit
d419ac21556dddb7b440df4657340a9ad2cb7644
substance/texture,substance/texture
src/article/ArticleNavPackage.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nangular.module('<%= scriptAppName %>')\n .directive('<%= cameledName %>', function () {\n return {\n template: '<div></div>',\n restrict: 'EA',\n link: function (scope, element, attrs) {\n elem...
javascript
edit
null
null
mit
b74fbefd56355f6faabae1e6aacdc8dc4b1fee9b
joelcoxokc/generator-ng-components
templates/directiveSimple/name.directive.js
rejected_syntax
Syntax error detected by tree-sitter
false
[ { "role": "user", "content": "Write javascript code for the following: Support babel on browser process" }, { "role": "assistant", "content": "require('coffee-script/register');\nrequire('babel-register')(require('./babel.config'));\nrequire('./lib/cl');\nrequire('./app');\n" } ]
javascript
new_file
0
0
mit
d71bed3234dd21cf8645b75efb289eaede91f827
syncsyncsynchalt/poi,syncsyncsynchalt/poi,syncsyncsynchalt/poi,syncsyncsynchalt/poi,poooi/poi,yudachi/poi,yudachi/poi,poooi/poi,poooi/poi,KagamiChan/poi,PHELiOX/poi,poooi/poi,KagamiChan/poi,yudachi/poi,gnattu/poi,gnattu/poi,PHELiOX/poi
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nfunction validateCacheSize(cacheSize) {\n if (cacheSize === undefined) {\n throw new Error('Missing the required property `cacheSize`.');\n }\n if (!Number.isInteger(cacheSize) || cacheSize <= 0) {\n throw new Error(\n 'Th...
javascript
edit
0
4
mit
2acab62b6c86558b30460c294329ee321f204c4c
toomuchdesign/re-reselect,toomuchdesign/re-reselect
src/cache/util/validateCacheSize.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar util = require('util')\nvar assert = require('assert')\nvar Transform = require('stream').Transform\n\nvar ChangesResponse = module.exports = function(options) {\n var self = this\n\n self._type = options.type || 'normal'\n self....
javascript
edit
0
5
mit
56421fc92eb48b3af4965eaab4f6d34aa0961828
mmalecki/couchdb-changes-response
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\nconst gutil = require('gulp-util');\nconst through = require('through2');\nconst meta = require('jsforce-metadata-tools');\n\nmodule.exports = function(options) {\n return through.obj(function(file, enc, callback) {\n ...
javascript
edit
0
4
mit
68d8670f5bc382df3e0303e44bd26f5a5723e65d
scolladon/sfdc-ci-toolkit,scolladon/sfdc-ci-toolkit
lib/plugins/gulp-jsforce-deploy.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* jshint node: true */\n'use strict';\n\nvar derequire = require('broccoli-derequire');\n\nmodule.exports = {\n name: 'ember-derequire',\n\n included: function(app) {\n this._super.included.apply(this, arguments);\n this.option...
javascript
edit
0
4
mit
b352849fed2f23ebc698913a67638e8bfa21c651
raikoroje/ember-derequire,raikoroje/ember-derequire
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport EventEmitter from \"events\";\nimport PubNub from \"pubnub\";\n\nexport default class Subscriptions extends EventEmitter {\n constructor() {\n super();\n this.subscribers = {};\n }\n\n getOrAddSubscriber(subscribeKey) {\...
javascript
edit
0
9
isc
58ae5e4ade8e4be8de0cec3a85c65e88fa3ba839
sibartlett/homebridge-wink3,sibartlett/homebridge-wink3,sibartlett/homebridge-wink3
src/Subscriptions.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * @class CM_FormField_Set_Select\n * @extends CM_FormField_Set\n */\nvar CM_FormField_Set_Select = CM_FormField_Set.extend({\n\t_class: 'CM_FormField_Set_Select'\n});\n```\n\nApply this change: Fix select to trigger change event" ...
javascript
edit
0
1
mit
698dff4aebc5643672fb85e1ef56853af0ba916d
zazabe/cm,vogdb/cm,fauvel/CM,cargomedia/CM,fvovan/CM,zazabe/cm,mariansollmann/CM,cargomedia/CM,fauvel/CM,vogdb/cm,mariansollmann/CM,christopheschwyzer/CM,zazabe/cm,vogdb/cm,njam/CM,mariansollmann/CM,alexispeter/CM,zazabe/cm,christopheschwyzer/CM,njam/CM,alexispeter/CM,christopheschwyzer/CM,mariansollmann/CM,christophes...
library/CM/FormField/Set/Select.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nfunction Supercollider() {\n this.options = {};\n this.searchOptions = {};\n this.adapters = {};\n this.tree = [];\n this.template = null;\n}\n\nSupercollider.prototype.init = require('./lib/init');\nSupercollider.prototype.parse =...
javascript
edit
0
1
mit
989d2e6eb5aa10c877cdff21e49a0bda89eb6546
gakimball/supercollider,spacedoc/spacedoc,spacedoc/spacedoc
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\ndescribe('My module', () => {\n beforeEach(() => {\n myModule = injectLoaderCompatibility(\n __dirname,\n '../src/my-module.js',\n {\n 'events': eventsMock,\n '../lib/dispatcher': dispatcherMock,\n ...
javascript
edit
0
1
mit
6e9d992e8b771797538db6639fecfb298b402686
0xR/graphql-clients-slides,0xR/graphql-clients-slides
includes/inject-loader.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nTemplate.postSubmit.events({\n 'submit form': function(e) {\n e.preventDefault();\n\n var post = {\n url: $(e.target).find('[name=url]').val(),\n title: $(e.target).find('[name=title]').val()\n };\n\n post.slug = ...
javascript
edit
0
2
mit
d540d855dd4834f1eec4445c418a2ea18075a19e
drainpip/music-management-system,drainpip/music-management-system
app/client/templates/posts/post_submit.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar React = require('react/addons');\n\nvar Notification = React.createClass({\n\n /**\n * @function hide\n * @description Focus on the element.\n */\n open: function () {\n this.setState({\n active: true\n });\n },\...
javascript
edit
0
1
mit
be86d5b83c3bbcf50b53e6b1bb87508d4a8f19c8
pburtchaell/react-notification
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React from 'react';\nimport { CircularProgress } from 'material-ui';\n\nconst Loading = () => (\n <div style={{textAlign: 'center'}}>\n <CircularProgress mode='indeterminate' />\n </div>\n);\n\nexport default Loading;\n\n```...
javascript
edit
0
2
cc0-1.0
f0f2a4e79d9077289b96a20fc61980b339881f11
mojotech/pivotal-swimlanes,mojotech/pivotal-swimlanes,djkirby/pivotal-swimlanes,djkirby/pivotal-swimlanes,mojotech/pivotal-swimlanes
src/components/shared/Loading.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport test from 'ava'\nimport any from '../../packages/any'\n\ntest('any() of an empty array returns false', t => {\n t.is(any(i => i, []), false)\n})\n\ntest('any() of a list that fully matches the predicate function returns true', t...
javascript
edit
0
1
mit
45dcb8289d6fabea5c0e565263736cf6d1579354
goblindegook/funny
test/any/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport chai from 'chai';\nimport Game from '../lib/game';\nimport $ from \"jquery\";\nconst expect = chai.expect;\n\ndescribe('game', function () {\n after(function() {\n $('.game-table').remove();\n });\n\n context('start', funct...
javascript
edit
0
1
mit
b6b89d8ba4737f1080ef99e5438767794cedfea4
Claudia108/puzzlenary,Claudia108/puzzlenary
test/game-test.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/**\n * @license\n * Copyright 2019 The FOAM Authors. All Rights Reserved.\n * http://www.apache.org/licenses/LICENSE-2.0\n */\n\nfoam.CLASS({\n package: 'foam.nanos.ruler',\n name: 'RuleHistory',\n documentation: 'Represents rule ex...
javascript
edit
0
0
apache-2.0
2b97f7772ec5884a9d643341528c5b1e3fae51ae
jacksonic/vjlofvhjfgm,foam-framework/foam2,foam-framework/foam2,jacksonic/vjlofvhjfgm,jacksonic/vjlofvhjfgm,foam-framework/foam2,foam-framework/foam2,foam-framework/foam2
src/foam/nanos/ruler/RuleHistory.js
rejected_duplicate
Near-duplicate of sample 80189
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar DeviceInformationLoader = function (require, exports, module) {\n var exec = require(\"cordova/exec\");\n \n function DeviceInformation () {}\n \n DeviceInformation.prototype.get = function (successFunc, failFunc)...
javascript
edit
0
1
mit
9f90f64aa998c814b4994bba3e3c82c350363b41
UpChannel/DeviceInformationPlugin,UpChannel/DeviceInformationPlugin
www/deviceinformation.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-cli-content-for-config'\n};\n\n```\n\nApply this change: Allow a user to get the content out of the config" }, { "role": "assistant", "content": "/...
javascript
edit
0
4
mit
93917a9b2f58b9b314633d11fc65e40d05de3acb
bmac/ember-cli-content-for-config,bmac/ember-cli-content-for-config
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst { compress } = require('csso').syntax;\nconst postcssToCsso = require('./lib/postcssToCsso.js');\nconst cssoToPostcss = require('./lib/cssoToPostcss.js');\n\nmodule.exports = (options = {}) => ({\n postcssPlugin: 'postcss-csso'...
javascript
edit
0
1
mit
172de9f28296c4dc6dd87920515ce4b27c09a3ea
lahmatiy/postcss-csso
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n$(document).ready(function(){\n\n $('nav').children().eq(3).on('click', function(event){\n console.log(\"hi\")\n $.ajax({\n\n })\n })\n\n})\n\n```\n\nApply this change: Fix jquery call to point to correct item/blog" }, { ...
javascript
edit
0
1
mit
7979f90d1e57bfd02c281a407bd8fba220c2bd01
Bigless27/Personal-Website-2.0,Bigless27/Personal-Website-2.0,Bigless27/Personal-Website-2.0
personal_website/app/assets/javascripts/blogs.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nprocess.stdin.resume();\nprocess.stdin.setEncoding('utf8');\n\nvar input = '';\n\nprocess.stdin.on('data', function(chunk) {\n input += chunk;\n});\n\nprocess.stdin.on('end', function() {\n\n var lines = input.trim().split('\\n');\n\n...
javascript
edit
0
7
mit
dd294b1cb2ea23232ac0ebf10e3d016f01f43081
inotom/js-stdin-example
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport DS from 'ember-data';\n\nexport default DS.Transform.extend({\n deserialize: function(serialized) {\n var map = {\n 0: 'New',\n 4: 'Opened',\n 8: 'Closed',\n 10: 'Verified',\n 20: 'Started',\n 30...
javascript
edit
0
1
bsd-2-clause
00d3ac53781806cac5c12e84d1ad31e859b11535
barberscore/barberscore-web,barberscore/barberscore-web,barberscore/barberscore-web
app/transforms/session-status.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n// setup JSDOM\nrequire('jsdom-global')()\n\n// make document and global available globally\nconst jsdom = require('jsdom')\nconst { JSDOM } = jsdom\nconst { document } = (new JSDOM('')).window\nglobal.document = document\nglobal.window...
javascript
edit
0
2
mit
8eb948953385dfea68605027168c0230a9bbec96
X-Ryl669/kutr,phanan/koel,phanan/koel,phanan/koel,X-Ryl669/kutr,X-Ryl669/kutr
resources/assets/js/tests/setup.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar path = require('path');\nvar pkg = require('./package.json');\n\nvar jeetPath = path.join(__dirname, 'styl')\n\nexports = module.exports = function (opts) {\n return function (style) {\n style.import(jeetPath);\n }\n}\n\nexport...
javascript
edit
0
2
mit
e95edabe1b5f36f65e0e15e040fb5871d6d7e13d
mojotech/jeet,mojotech/jeet
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: 'roundcube-mail',\n isDevelopingAddon: function() {\n return true;\n },\n included: function (app) {\n this._super.included(app);\n\n app.import(app.bower...
javascript
edit
0
1
mit
db1da65dc2076b9e15180574e5ff7dddb8a6e332
roundcube-next/roundcube-mail,roundcube-next/roundcube-mail
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar repeat = require('lodash.repeat');\n\nmodule.exports = function(md, opts) {\n // default to being two spaces wide\n if (!opts || typeof opts.tabWidth === 'undefined') {\n tabWidth = 2;\n } else {\n tabWidth = Math.max(0, op...
javascript
edit
0
4
isc
5f1f1ad5de2fa40536a14f9f79e8767ccc69ba1a
revin/markdown-it-expand-tabs
index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport Component from '@ember/component';\nimport {computed} from '@ember/object';\nimport {inject as service} from '@ember/service';\n\nexport default Component.extend({\n router: service(),\n config: service(),\n ghostPaths: ...
javascript
edit
0
1
mit
d35692b08851b2ec761a8e1550e56ff060a4cce7
TryGhost/Ghost-Admin,TryGhost/Ghost-Admin
app/components/gh-billing-update-button.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n'use strict';\n\nconst lost = require('lost');\nconst pxtorem = require('postcss-pxtorem');\nconst autoprefixer = require('autoprefixer');\n\nmodule.exports = [\n lost(),\n pxtorem({\n rootValue: 16,\n unitPrecision: 5,\n pro...
javascript
edit
0
0
mit
1ff95e89823bd458e9123d8999036dec70f0af46
wpioneer/gatsby-starter-lumen,nicklanasa/nicklanasa.github.io,ochaloup/blog.chalda.cz,renegens/blog,ochaloup/blog.chalda.cz,alxshelepenok/gatsby-starter-lumen,hb-gatsby/gatsby-starter-lumen,nicklanasa/nicklanasa.github.io,alxshelepenok/gatsby-starter-lumen,renegens/blog
postcss-config.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar element = {\n form: '#openAccForm',\n firstNameInput: '#fname',\n familyNameInput: '#lname',\n emailInput: '#Email',\n dateofBirthInputs: '???',\n firstLineAddressInput: '#Address1',\n townCityInput: '#AddressTo...
javascript
edit
0
1
apache-2.0
d91307e5ff0c86807466995beff7bce1823104e8
borisyankov/binary-static,brodiecapel16/binary-static,brodiecapel16/binary-static,animeshsaxena/binary-static,borisyankov/binary-static,brodiecapel16/binary-static,junbon/binary-static-www2,einhverfr/binary-static,junbon/binary-static-www2,massihx/binary-static,massihx/binary-static,borisyankov/binary-static,animeshsax...
test/integration/tests/auth/createAccountRealMoneyFail.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport {\n REMOVE_MEDIA_TO_TWEET,\n UPLOADED_MEDIA_TO_TWEET\n} from '../constants/ActionTypes';\n\nconst initialState = {\n medias: [],\n};\n\nexport default function mediaToTweet(state = initialState, action) {\n switch (action.typ...
javascript
edit
0
4
mit
f62c9aea137c487411cd06785016676b09593722
wozaki/twitter-js-apps,wozaki/twitter-js-apps
redux/src/main/renderer/reducers/mediaToTweet.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst express = require('express');\nconst router = express.Router();\n\nconst db = require('../queries');\n\nrouter.get('/api/todos', (req, res, next) => {\n db.getAllTodos()\n .then(todos => {\n res.render('index', { todos })...
javascript
edit
0
2
mit
199261779e8e3f8b580e09f7603260852f6b0700
spencerdezartsmith/to-do-list-app,spencerdezartsmith/to-do-list-app
server/routes/index.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst Kaba = require(\"kaba\");\n\nmodule.exports = (new Kaba())\n .addJavaScriptEntries({\n \"all-tests\": \"tests/build/all-tests.js\",\n })\n .setOutputPath(\"tests/dist\")\n .disableChunkSplitting()\n .disableF...
javascript
edit
0
0
bsd-3-clause
1469de61e89496cfaf8cc48df3e1b6cd5d1b8d64
Becklyn/mojave,Becklyn/mojave,Becklyn/mojave
kaba.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nwindow.ga = window.ga || function(...args) { (ga.q = ga.q || []).push(args); }; ga.l = Number(new Date());\n\nga('create', $DIM_VERSION === 'release' ? 'UA-60316581-1' : 'UA-60316581-5', 'auto');\nga('set', 'dimension1', $DIM_VERSION);\...
javascript
edit
0
2
mit
e77f9520f37c4393a0117a904b5587039ddaca49
DestinyItemManager/DIM,delphiactual/DIM,chrisfried/DIM,bhollis/DIM,bhollis/DIM,chrisfried/DIM,delphiactual/DIM,DestinyItemManager/DIM,DestinyItemManager/DIM,bhollis/DIM,chrisfried/DIM,bhollis/DIM,delphiactual/DIM,chrisfried/DIM,DestinyItemManager/DIM,delphiactual/DIM
src/app/google.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar Msg = require(\"../../models/msg\");\n\nmodule.exports = function(irc, network) {\n\tvar client = this;\n\tirc.on(\"notice\", function(data) {\n\t\tvar lobby = network.channels[0];\n\t\tvar from = data.from || \"\";\n\t\tif (data.to...
javascript
edit
0
6
mit
560de1ac38a7afb8b25ebcaf3d444a05a74f015e
libertysoft3/lounge-autoconnect,Audio/shout,rockhouse/lounge,karen-irc/karen,cha2maru/shout,run-project/shout,metsjeesus/lounge,togusafish/floogulinc-_-Shuo,togusafish/floogulinc-_-Shuo,astorije/shout,thelounge/lounge,diddledan/shout,MaxLeiter/lounge,Calinou/shout,olivierlambert/shout,MaxLeiter/shout,williamboman/loung...
src/plugins/irc-events/notice.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar github = (function(){\n function escapeHtml(str) {\n return $('<div/>').text(str).html();\n }\n function render(target, repos){\n var i = 0, fragment = '', t = $(target)[0];\n\n for(i = 0; i < repos.length; i++) {\n ...
javascript
edit
0
7
mit
cc93e6fc98777418544eccd81f106b42dd915f5b
teracyhq/blog,eswdd/eswdd.github.io,alastairs/bobthebuilder-website,BWieber/bwieber.github.io,rishma/rishma.github.io,takus/takus.github.com,evidal/www.eric-vidal.com,rishiip/rishiip.github.io,rishma/rishma.github.io,siddhartha-gadgil/BasicAnalysisCourse,MrZoidberg/merkulov.me,siddhartha-gadgil/LogicTypesSpaces,evidal/...
.themes/classic/source/javascripts/github.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport React, { PropTypes } from 'react';\nimport VarOneStore from '../../stores/varOne-store';\nimport connectToStores from 'alt/utils/connectToStores';\n\n\n@connectToStores\nexport default class VarOneLogModal extends React.Component...
javascript
edit
0
1
mit
c472a81494fb979107e77da3e89c8b900d373c1e
SparkMonitor/varOne,SparkMonitor/varOne,SparkMonitor/varOne,SparkMonitor/varOne
varOne-web/src/main/webapp/app/components/commons/varOne-log-modal.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nvar app = require('app');\nvar chokidar = require('chokidar');\nvar extend = require('util')._extend;\nvar fs = require('fs');\n\nvar bootstrap = function(glob, options) {\n options = options || {};\n var browserWindows = [];\n var o...
javascript
edit
0
4
mit
0610df2860afdb9323b693eef64f6358df2b0338
yan-foto/electron-reload
main.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n\"use strict\";\n\nangular.module(\n 'arethusa', [\n 'mm.foundation',\n 'ngRoute',\n 'arethusa.core',\n 'arethusa.morph',\n 'arethusa.hist'\n ],\n function($routeProvider, MAIN_ROUTE) {\n $routeProvider.when('/', MA...
javascript
edit
0
1
mit
e14b3ea6dbb4b475958f59f0ae4ef85e1ce96b4e
alpheios-project/arethusa,latin-language-toolkit/arethusa,fbaumgardt/arethusa,alpheios-project/arethusa,latin-language-toolkit/arethusa,fbaumgardt/arethusa,PonteIneptique/arethusa,fbaumgardt/arethusa,Masoumeh/arethusa,PonteIneptique/arethusa,alpheios-project/arethusa,Masoumeh/arethusa
app/js/arethusa.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nimport get from 'lodash/get';\n\nconst isEmptyMetadata = (metadata) => {\n const keys = [\n 'description',\n 'citation',\n 'source',\n 'applicationProperties.cautions',\n 'applicationProperties.function',\n 'applicati...
javascript
edit
0
3
mit
b10a76c55bd90bc02f470e066ab98b71477eb759
Vizzuality/forest-atlas-landscape-cms,Vizzuality/forest-atlas-landscape-cms,Vizzuality/forest-atlas-landscape-cms,Vizzuality/forest-atlas-landscape-cms
app/javascript/components/shared/Dashboard/dashboard.helpers.js
rejected_duplicate
Near-duplicate of sample 77688
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n/* eslint no-console: 0 */\n'use strict';\n\nconst phantom = require('phantom');\n\n\nfunction* blockResourceLoading(page) {\n yield page.property('onResourceRequested', function(requestData, request) {\n var BLOCKED_RESOURCES...
javascript
edit
0
3
mit
f9bd3bfe2df60bd0c00e82faea5013777d03db22
lesh1k/vkstalk-js,lesh1k/vkstalk-js
src/phantom_helpers.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\n#!/usr/bin/env node\n\n/* \n\n ___ usage ___ en_US ___\n usage: dots git issue create [options] [subject]\n\n desciption:\n\n Create a GitHub issue from the command line using the given subject. If the\n creation is succe...
javascript
edit
0
1
mit
bbc137799221cb89f032253df2b9e6330ac81202
bigeasy/dotfiles,bigeasy/dotfiles,bigeasy/dotfiles
lib/dots/bin/node/travis.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nfunction resizeWhich(img) {\n img.removeAttr('style');\n\n if (window.innerWidth / img.width() < window.innerHeight / img.height()) {\n return 'width';\n console.log('Set width to 100%')\n } else {\n return...
javascript
edit
0
2
mit
0b0d09543e7546392e78eed725a9694328a8af19
cdriehuys/chmvh-website,cdriehuys/chmvh-website,cdriehuys/chmvh-website
chmvh_website/gallery/static/js/gallery.js
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```javascript\nconst eol = require('eol');\nconst commentsUtil = require('../utils/comments');\n\nmodule.exports = function(params) {\n params = params || {};\n const regex = commentsUtil.getRegex(params.customTags);\n const commentsRegex = n...
javascript
edit
0
2
mit
cad33ba31249653f826d0c05267deb03bf0a2ac9
pgilad/leasot,pgilad/leasot,pgilad/leasot
lib/parsers/coffeeParser.js
accepted
null
true