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\nimport { reducer as form } from 'redux-form';\nimport okapiReducer from './okapiReducer';\nimport { discoveryReducer } from './discoverServices';\n\nexport default {\n // TODO: here's where you'd pull in a reducer to handle Okapi actio... | javascript | edit | 0 | 0 | apache-2.0 | 743b34469b870f47acc97973accb9f7b92c8e3cb | folio-org/stripes-core,folio-org/stripes-core,folio-org/stripes-core | src/initialReducers.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar chai = require(\"chai\");\nchai.Should();\nchai.use(require('chai-things'));\nchai.use(require('signalk-schema').chaiModule);\n\nvar mapper = require(\"../n2kMapper.js\");\n\n\ndescribe('129039 Class B Update', function () {\n it('... | javascript | edit | 0 | 1 | apache-2.0 | bc692a8b85694dd231588a223b34ea32ba8849b6 | SignalK/n2k-signalk | test/129809_ais_class_b_static_data.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport React from 'react';\n\nimport { withScrollToTop } from '../hocs/withScrollToTop';\n\nimport FeaturedItems from '../FeaturedItems';\n\nimport { Header, Status } from './styled';\n\nconst Bookmarks = ({ savedJobs = [], data, logged... | javascript | edit | 0 | 4 | mit | 918d1eafc61fc406249114c6368bde438ec74588 | jenovs/bears-team-14,jenovs/bears-team-14 | client/src/components/Bookmarks/Bookmarks.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport { stringify } from 'querystring'\nimport React from 'react'\nimport PropTypes from 'prop-types'\nimport moment from 'moment'\nimport { withRouter } from 'next/router'\nimport { translate } from 'react-i18next'\n\nimport Dropdown ... | javascript | edit | 0 | 2 | mit | 3a9a202817b20cc00d3fc4b558a00425d965da38 | sgmap/inspire,sgmap/inspire | components/page/header/language-selection.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * head.script.js\n *\n * Essential scripts, to be loaded in the head of the document\n * Use gruntfile.js to include the necessary script files.\n */\n\n// Load respimage if <picture> element is not supported\nif(!window.HTMLPictu... | javascript | edit | 0 | 0 | mit | d0337c801ae406538f98e9503449baaab12507f9 | jolantis/altair,jolantis/altair | assets/javascript/head.scripts.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst openstackBackupRestoreSummary = {\n template: '<openstack-instance-checkout-summary ng-if=\"$ctrl.context.resource\" model=\"$ctrl.summaryModel\"/>',\n bindings: {\n model: '<',\n field: '<',\n context: '<',\n },\n co... | javascript | edit | 0 | 2 | mit | 362bd33a93a7fe98d4eb92552ae17f093724d0f9 | opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport | app/scripts/components/openstack/openstack-backup/openstack-backup-restore-summary.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n// Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors\n// MIT License. See license.txt\n\nfrappe.ui.toolbar.Search = frappe.ui.toolbar.SelectorDialog.extend({\n\tinit: function() {\n\t\tthis._super({\n\t\t\ttitle: fra... | javascript | edit | 0 | 1 | mit | 1b43b73887930d6809652e1ee1b20b257008035b | gangadharkadam/saloon_frappe,bohlian/frappe,Tejal011089/digitales_frappe,pranalik/frappe-bb,indictranstech/phr-frappe,indictranstech/trufil-frappe,sbktechnology/sap_frappe,aboganas/frappe,gangadharkadam/office_frappe,manassolanki/frappe,mhbu50/frappe,gangadharkadam/tailorfrappe,manassolanki/frappe,suyashphadtare/sajil-... | frappe/public/js/frappe/ui/toolbar/search.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/* eslint no-var: 0 */\nvar objectAssign = require('object-assign');\nvar webpack = require('webpack');\nvar baseConfig = require('./base.config');\n\nmodule.exports = objectAssign(baseConfig, {\n entry: './src/index.js',\n plugins: [... | javascript | edit | 0 | 0 | mit | 81f22cfed7c6f61edf6065d00d50735e760a3a34 | webkom/lego-webapp,webkom/lego-webapp,webkom/lego-webapp | webpack/prod.config.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar socket = io();\n//var verifyNameFormState = false;\n\nsocket.on('moderate name', function(msg){\n $('#currentName').text(msg);\n});\n\n$('#accept').click(function(e){\n // Prevent JavaScript from doing normal functionality\n e.... | javascript | edit | 0 | 1 | mit | aeb2562d36fae72763113a2603a95c2db5cb0128 | 2016-ksu-cis-open-house/tree-display,2016-ksu-cis-open-house/tree-display,2016-ksu-cis-open-house/tree-display | static/js/moderator.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar m = require('mithril');\n\nmodule.exports = function() {\n self = this;\n\n self.domains = [];\n self.currentDomain = m.prop('');\n\n self.init = function() {\n\n m.request({method: \"GET\", url: \"/api/v1/domains... | javascript | edit | 0 | 1 | mit | c2ce3a82155cdd03822a8359e35c68c896975fad | chrisseto/dinosaurs.sexy,chrisseto/dinosaurs.sexy | dinosaurs/js/controllers/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * @module ol/webgl/Buffer\n */\nimport _ol_webgl_ from '../webgl.js';\n\n/**\n * @enum {number}\n */\nconst BufferUsage = {\n STATIC_DRAW: _ol_webgl_.STATIC_DRAW,\n STREAM_DRAW: _ol_webgl_.STREAM_DRAW,\n DYNAMIC_DRAW: _ol_webgl... | javascript | edit | 0 | 3 | bsd-2-clause | 744cea642166ad67b8f0a35331d96ca246092636 | ahocevar/ol3,fredj/ol3,mzur/ol3,openlayers/openlayers,openlayers/openlayers,ahocevar/openlayers,geekdenz/openlayers,stweil/openlayers,adube/ol3,ahocevar/openlayers,fredj/ol3,tschaub/ol3,bjornharrtell/ol3,mzur/ol3,stweil/openlayers,gingerik/ol3,oterral/ol3,mzur/ol3,tschaub/ol3,bjornharrtell/ol3,geekdenz/ol3,geekdenz/ope... | src/ol/webgl/Buffer.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\ndefine([\n 'vehicle-licensing/collections/services',\n 'extensions/views/timeseries-graph/timeseries-graph',\n 'extensions/views/tabs',\n 'extensions/views/graph/headline',\n],\n function (ServicesCollection, TimeseriesGraph, Tabs,... | javascript | edit | 0 | 1 | mit | e80c620a958020e3221335a872a7439eae9233e6 | gds-attic/limelight,gds-attic/limelight,gds-attic/limelight | app/assets/javascripts/vehicle-licensing/controllers/vehicle-license-volumes-module.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar context;\nwindow.addEventListener('load', init, false);\nfunction init() {\n\ttry {\n\t var dogBarkingUrl = 'https://commons.wikimedia.org/wiki/File:Sound-of-dog.ogg';\n\t\tvar dogBarkingBuffer = null;\n\t\t// Fix up prefixing\n\t\... | javascript | edit | 0 | 3 | mit | c6dc08c0f1fc84c64a3590c98ad25bdb3585d1c3 | Rholais/voice-share,Rholais/voice-share | web-audio/web-audio.js | rejected_duplicate | Near-duplicate of sample 88760 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * Show the display name of the sample for navigation \n * @public \n * @return {String}\n * @properties={typeid:24,uuid:\"EB63D830-02F7-4CE4-BC4F-96E36F200217\"}\n */\nfunction getName(){\r\n\tthrow 'Method must be implemented'\r\... | javascript | edit | 0 | 1 | mit | 55f175646889a2dabd957d80272994e13d121487 | Servoy/svyMicroSamples,Servoy/svyMicroSamples,Servoy/svyMicroSamples | svyMicroSamples/forms/AbstractMicroSample.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nvar utils = require('../../../utils');\n\nvar localUtils = require('../utils');\nvar massageIndexDef = localUtils.massageIndexDef;\n\nfunction getIndexes(db) {\n // just search through all the design docs and filter in... | javascript | edit | 0 | 2 | apache-2.0 | ae932c0bb6e8c3ea6457ab810687afa0bfdb584d | cdaringe/pouchdb,seigel/pouchdb,tyler-johnson/pouchdb,tyler-johnson/pouchdb,cdaringe/pouchdb,seigel/pouchdb,pouchdb/pouchdb,cdaringe/pouchdb,tyler-johnson/pouchdb,seigel/pouchdb,pouchdb/pouchdb,pouchdb/pouchdb | packages/node_modules/pouchdb-find/lib/adapters/local/get-indexes/index.js | rejected_duplicate | Near-duplicate of sample 88916 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar test = require('selenium-webdriver/testing');\nvar server = require('./server');\nglobal.driver = null;\n\nfunction setUpDriverFor(test) {\n test.before(function() {\n var webdriver = require('selenium-webdriver');\n var chro... | javascript | edit | 0 | 2 | apache-2.0 | 32a63c1fa66b14b7fe0e5274a4d084e93435f45e | shyamalschandra/field-kit,daverome/field-kit,damiankaplewski/field-kit,greyhwndz/field-kit,daverome/field-kit,square/fieldkit,BionicClick/field-kit,paultyng/field-kit,UmarMughal/field-kit,janusnic/field-kit,janusnic/field-kit,square/field-kit,square/fieldkit,greyhwndz/field-kit,paultyng/field-kit,BionicClick/field-kit,... | test/selenium/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport {h} from 'dom-chef';\nimport select from 'select-dom';\nimport * as pageDetect from '../libs/page-detect';\n\nconst repoUrl = pageDetect.getRepoURL();\n\nexport default function () {\n\tconst canDeleteFork = select.exists('.repon... | javascript | edit | 0 | 6 | mit | 8e97db3f914ab8410e3890d6872d7b59076a524d | sindresorhus/refined-github,sindresorhus/refined-github,busches/refined-github,busches/refined-github | source/features/add-delete-fork-link.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n#!/usr/bin/env node\n\nvar child;\nvar exec = require('child_process').exec;\n\nexec('tsd reinstall -s');\n\n```\n\nApply this change: fix(build): Use the new `typings` instead of the deprecated `tsd`"
},
{
"role": "assistant",
... | javascript | edit | 0 | 0 | mit | 85ce5556585c89fbd93c662e3c8e5ada9dca1c7c | rixrix/stencil,rixrix/stencil,rixrix/stencil | scripts/install.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst Tags = require(\"../models/\").Tags;\n// const Article = require('../models/').Article;\n\nexports.addTags = (tags, articleId) => {\n // console.log(\"tags\", tags);\n tags.forEach(async tag => {\n await Tags.findOne({ tag: t... | javascript | edit | 0 | 3 | mit | 45e2d5a3e89bb03f33140cf3775db7cbb7a0f414 | wuwzhang/koa2-react-blog-wuw,wuwzhang/koa2-react-blog-wuw | server/lib/tags.js | accepted | null | true |
[
{
"role": "user",
"content": "Write javascript code for the following: Add JS for solo challenge"
},
{
"role": "assistant",
"content": "var madLibs = function() {\n var storyDiv = document.getElementById(\"story\");\n var name = document.getElementById(\"name\").value;\n var adjective =... | javascript | new_file | 0 | 1 | mit | 1b6bebbd342000d007210d958fc82dfebdfd22c9 | sharonjean/sharonjean.github.io,sharonjean/sharonjean.github.io | scripts/madlibs.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\ndescribe('FooterCtrl', function() {\n var FooterCtrl;\n\n beforeEach(function() {\n module('yourStlCourts');\n\n inject(function($controller) {\n FooterCtrl = $controller('FooterCtrl', {});\n });\n });\... | javascript | edit | 0 | 1 | mit | 3e0e7ab1b3034d774787685c78b53ba4664c823e | OpenDataSTL/gh-angular,OpenDataSTL/STLCourts-client,OpenDataSTL/gh-angular,OpenDataSTL/STLCourts-client | test/spec/controllers/footer.ctrl.spec.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\ndescribe('Encryption', () => {\n\tit('apply encryption and decryption to get original message', done => {\n\t\twindow.newEncryptionKey().then(key => {\n\t\t\tconst message = 'The quick brown fox jumps over the lazy dog';\n\t\t\tconst en... | javascript | edit | 0 | 2 | mit | d68b4f628e9ff821096f522ef730836808a0f968 | Metalnem/javascript-crypto,Metalnem/javascript-crypto | spec/encryption.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\ntbTable.$inject = [ 'tableBuilder' ];\n\nfunction tbTable(tableBuilder) {\n var directive = \n {\n restrict: 'E',\n scope: {\n schema: '=',\n model: '=',\n onRowClick: '=?'\n }... | javascript | edit | 0 | 2 | mit | 4dafd365c46539a1ece52787e818e657be655568 | Tribu-Anal/Vinculacion-Front-End,Tribu-Anal/Manejo-Horas-de-Vinculacion-UNITEC,Tribu-Anal/Manejo-Horas-de-Vinculacion-UNITEC,Tribu-Anal/Vinculacion-Front-End | dev/app/shared/TB-Table/tb-table.directive.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport React from 'react';\n\nclass Quantity extends React.Component {\n render() {\n return (\n <div className=\"container__row figure -left -center\">\n <div className=\"figure__media\">\n <div className=\"qua... | javascript | edit | 0 | 3 | mit | d88b287fe9bf8c23f5c6e6857358a7b644da43e3 | DoSomething/rogue,DoSomething/rogue,DoSomething/rogue | resources/assets/components/Quantity/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\n(function(Rubeus) {\n\n Rubeus.cfg.s3 = {\n\n uploadMethod: 'PUT',\n uploadUrl: null,\n uploadAdded: function(file, item) {\n var self = this;\n var parent = self.getByID(item.parentID);\n... | javascript | edit | 0 | 3 | apache-2.0 | 2af3b102bfb5fc29b585c147424978af8246a6a6 | jeffreyliu3230/osf.io,Nesiehr/osf.io,fabianvf/osf.io,Johnetordoff/osf.io,chennan47/osf.io,acshi/osf.io,fabianvf/osf.io,KAsante95/osf.io,leb2dg/osf.io,arpitar/osf.io,hmoco/osf.io,brandonPurvis/osf.io,mfraezz/osf.io,jmcarp/osf.io,asanfilippo7/osf.io,crcresearch/osf.io,acshi/osf.io,doublebits/osf.io,pattisdr/osf.io,cosena... | website/addons/s3/static/s3-rubeus-cfg.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nvar BaseGenerator = require('yeoman-generator').Base;\n\nmodule.exports = BaseGenerator.extend({\n\n constructor: function () {\n BaseGenerator.apply(this, arguments);\n this.option('preset', {desc: 'App preset: ... | javascript | edit | 0 | 1 | mit | 784efbf5bfcb989ad81b2d80fa504e028c1d6466 | catberry/generator-catberry,catberry/generator-catberry | generators/app/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar api = require('digio-api')\n, print = require('../print')\n, tools = require('../tools')\n\nvar domains = function (cmd, _config) {\n api = new api(tools.get_active_key(_config))\n\n cmd.register(\n 'domains',\n 'list',\n ... | javascript | edit | 0 | 2 | mit | 7a83bb03fc3ce21172e077abb96e9c32c676276d | digio/digio | lib/commands/domains.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar Promise = require('bluebird'),\n mongoose = Promise.promisifyAll(require('mongoose')),\n Group = mongoose.model('Group'),\n async = require('async'),\n collection;\n\nmodule.exports = {\n 'bootstrap' : BootStrap\n};\n\n... | javascript | edit | 0 | 2 | mit | 11795826c58e20530836f9be5f397004525f2c6a | Pranay92/collaborate,Pranay92/lets-chat | bootstrap/groups.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst ChildProcess = require('child_process')\nconst path = require('path')\n\nconst metadata = require('../package')\n\nconst command = path.join(__dirname, '..', 'node_modules', '.bin', 'electron-windows-store.cmd')\nconst args = [\n ... | javascript | edit | 0 | 1 | mit | 6b1709ef6dcff6eae728a10ab968d99ad45766db | electron/electron-api-demos,PanCheng111/XDF_Personal_Analysis,electron/electron-api-demos,electron/electron-api-demos,PanCheng111/XDF_Personal_Analysis,PanCheng111/XDF_Personal_Analysis,blep/electron-api-demos,blep/electron-api-demos,blep/electron-api-demos,blep/electron-api-demos | script/windows-store.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport { List as list } from 'immutable';\nimport { connect } from 'react-redux';\n\nimport { aBlockClicked } from '../../../actions/analysis.actions';\nimport { aContentBlockHovered } from '../../../actions/content.actions';\n\nimport ... | javascript | edit | 0 | 1 | mit | efc77260daf91531b7a2a0814424fccf8153baac | felamaslen/budget,felamaslen/budget,felamaslen/budget,felamaslen/budget,felamaslen/budget,felamaslen/budget | web/src/containers/page/analysis/blocks.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst dotenv = require('dotenv');\n\ndotenv.config();\n\nmodule.exports = {\n development: {\n username: 'Newman',\n password: 'andela2017',\n database: 'postit-db-dev',\n host: '127.0.0.1',\n port: 5432,\n secret_key... | javascript | edit | 0 | 0 | mit | 55b57b2b4c4df03b7b802c748a19c6489f7ef026 | Philipeano/post-it,Philipeano/post-it | server/config/config.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nmodule.exports = function(model) {\n 'use strict';\n\n let validateProjectAccess = require('./project-access')(model.access);\n let schema = require('.././schema')(model);\n let router = require('koa-router')();\n let pro... | javascript | edit | 0 | 1 | mit | f50d62e50cd231f214c0961079333ce17103bb93 | materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org | backend/server/resources/projects-routes.js | rejected_duplicate | Near-duplicate of sample 68706 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\ndefine([\n 'extensions/collections/collection'\n],\nfunction (Collection) {\n return {\n requiresSvg: true,\n collectionClass: Collection,\n\n collectionOptions: function () {\n var valueAttr = this.model.get('value-attr... | javascript | edit | 0 | 4 | mit | 6224f904b3cdb69e6b0016dd60554d009cef10c0 | alphagov/spotlight,keithiopia/spotlight,keithiopia/spotlight,alphagov/spotlight,tijmenb/spotlight,tijmenb/spotlight,tijmenb/spotlight,alphagov/spotlight,keithiopia/spotlight | app/common/modules/bar_chart_with_number.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport Ember from 'ember';\nimport layout from './template';\nimport config from 'ember-get-config';\n\n/**\n * @module ember-osf\n * @submodule components\n */\n\n/**\n * Render the provided url in an iframe via MFR\n *\n * Sample usag... | javascript | edit | 0 | 2 | apache-2.0 | 183fb094a02b1edea5d647d0a264be150f0c1bbe | CenterForOpenScience/ember-osf,binoculars/ember-osf,baylee-d/ember-osf,binoculars/ember-osf,baylee-d/ember-osf,jamescdavis/ember-osf,CenterForOpenScience/ember-osf,jamescdavis/ember-osf | addon/components/file-renderer/component.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar path = require(\"path\");\nvar mvc = exports = module.exports;\n\n/** \n * Enable having multiple folders for views to support the\n * module/mymodule/views structure \n */\nmvc.EnableMultipeViewsFolders = function(app) {\n // Monk... | javascript | edit | 0 | 4 | mit | 4bb05ad5e814c871a1d61141a54b51642b9d2214 | luiselizondo/expressjsmvc | lib/expressjsmvc.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * Users\n */\n\nMeteor.users.allow({\n insert: function() { return false; },\n update: function() { return false; },\n remove: function() { return false; }\n});\n\nMeteor.users.deny({\n insert: function() { return true; },\n ... | javascript | edit | 0 | 1 | mit | c05a3f0c135ebc257c8f50979f7760b65bda0ffe | etremel/signmeup,gregcarlin/signmeup,etremel/signmeup,signmeup/signmeup,athyuttamre/signmeup,etremel/signmeup,gregcarlin/signmeup,gregcarlin/signmeup,athyuttamre/signmeup,signmeup/signmeup | app/collections/users.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nangular.module('Game', ['Grid'])\n\n.service('GameManager', ['GridService', function(GridService) {\n // initialize service\n this.reinit = function() {\n this.currentScore = 0;\n this.bestScore = 0;... | javascript | edit | 0 | 2 | mit | 98f45dc65edc24f2188f19f36c8ae675e9ed64bf | derek-dchu/angular-2048 | app/scripts/game/game.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nwindow.aloft = window.aloft || {};\naloft.toggleFBComments = function () {\n if (!aloft.commentStyle) {\n var css = '.UFIComment {display: none;}', head = document.head || document.getElementsByTagName('head')[0], style = document.c... | javascript | edit | 0 | 4 | mit | 4db3b9164f752d447919009c1bc253b613205260 | tdukart/comments-b-gone,tdukart/comments-b-gone,tdukart/comments-b-gone | src/hideComments.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * No Description\n *\n * @return LocalStrings\n * @author Erik E. Lorenz <<EMAIL>>\n * @license MIT License\n * @see LICENSE\n */\ndefine(function() {\n return {\n teamsicon: 'teams',\n variant: 'Basic',\n teamtext: 'Tea... | javascript | edit | 0 | 1 | mit | 2d2e22b8038b893c2bad5ed194cf618b2d27a11c | elor/tuvero | basic/scripts/strings.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\nvar opn = require('open');\nvar http = require('http');\nvar fs = require('fs');\nvar url = require('url');\nvar path = require('path');\nvar Promise = require('bluebird');\n\nfunction hostLogin(domain, options) {\n re... | javascript | edit | 0 | 3 | apache-2.0 | 99a83beee06ea9ecbb71a67113f4863fa9ffd17b | OADA/oada-id-client-js,OADA/oada-id-client-js | src/node-browser.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * Modules dependencies\n */\n\nvar spec = require('stream-spec'),\n\ttester = require('stream-tester'),\n\tcsv = require('./../');\n\nvar options = {\n\tdelimiter : ','\n};\nvar stream = csv.createStream(options);\n\nspec(stream)\... | javascript | edit | 0 | 2 | mit | 3739858243c61cd66a9874e1e4fad478c896297f | russmatney/node-csv-stream,lbdremy/node-csv-stream | test/stream-spec.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n// ***********************************************************\n// This example support/index.js is processed and\n// loaded automatically before your test files.\n//\n// This is a great place to put global configuration and\n// behavio... | javascript | edit | 0 | 1 | mit | f7d70e9dd2ba87479c4d9e55b7caf366d9153e8f | pkarw/vue-storefront,DivanteLtd/vue-storefront,pkarw/vue-storefront,DivanteLtd/vue-storefront,DivanteLtd/vue-storefront,pkarw/vue-storefront,pkarw/vue-storefront,DivanteLtd/vue-storefront | cypress/support/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n* @ngdoc directive\n* @name umbraco.directives.directive:no-password-manager\n* @attribte\n* @function\n* @description\n* Added attributes to block password manager elements should as LastPass\n\n* @example\n* <example module=\"um... | javascript | edit | 0 | 1 | mit | 943e050493ccb9a3fcb84813bb1f39986753d8b5 | abjerner/Umbraco-CMS,JimBobSquarePants/Umbraco-CMS,dawoe/Umbraco-CMS,bjarnef/Umbraco-CMS,KevinJump/Umbraco-CMS,JimBobSquarePants/Umbraco-CMS,NikRimington/Umbraco-CMS,robertjf/Umbraco-CMS,umbraco/Umbraco-CMS,arknu/Umbraco-CMS,rasmuseeg/Umbraco-CMS,bjarnef/Umbraco-CMS,leekelleher/Umbraco-CMS,tcmorris/Umbraco-CMS,dawoe/Um... | src/Umbraco.Web.UI.Client/src/common/directives/util/noPasswordManager.directive.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar path = require('path');\nvar through = require('through');\nvar FileSystemLoader = require('css-modules-loader-core/lib/file-system-loader');\n\nvar cssExt = /\\.css$/;\nmodule.exports = function (filename) {\n // only handle .css ... | javascript | edit | 0 | 2 | mit | a680110480238f4af043909a3030753ce9d026d8 | LoganBarnett/css-modulesify,joeybaker/css-modulesify,bkvfoundry/css-modulesify,gilesvangruisen/css-modulesify,wenbing/css-modulesify,spion/css-modulesify,css-modules/css-modulesify | lib/index.js | rejected_duplicate | Near-duplicate of sample 80212 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nmodule.exports = function( web ) {\n\nweb.get( \"/\", function( request, response ) {\n\tvar app = web.get( \"debt\" );\n\n\tif ( app.state === \"database-setup\" ) {\n\t\treturn app.install(function( error ) {\n\t\t\tif ( error ) {\n\t... | javascript | edit | 0 | 3 | mit | 694ab2dab02fa11e33343749cd60f68e368fe615 | scottgonzalez/debt | lib/web/routes.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nmodule.exports = function (context, opts = {}) {\n const env = process.env.BABEL_ENV || process.env.NODE_ENV\n const isDevelopment = env === 'development'\n\n return {\n presets: [\n // Browsers are taken from the browserslis... | javascript | edit | 0 | 2 | mit | 94c081c389d1ef06fb7a5eb578f392af14bb1a30 | accurat/accurapp,accurat/accurapp,accurat/accurapp,accurat/accurapp | packages/babel-preset-accurapp/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use babel';\n\nimport {component} from './polymer-es6';\n\nconsole.log(\"AT VIDEO\");\n\n@component('at-video')\nexport class AtomTwitchVideo {\n static properties() {\n return { };\n }\n \n static listeners() {\n return { 'c... | javascript | edit | 0 | 2 | mit | d79591c07b080935369cc474b461c8438ed3b506 | paulcbetts/atom-twitch,paulcbetts/atom-twitch | lib/at-video.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n// Karma configuration\n// http://karma-runner.github.io/0.12/config/configuration-file.html\n\nmodule.exports = function(config) {\n 'use strict';\n\n config.set({\n basePath: '../',\n autoWatch: true,\n frameworks: ['jasmin... | javascript | edit | 0 | 1 | mit | 771a627d94c177bf537b8020a50294ba93263db6 | ga-wdi-boston/wdi_2_css_bootstrap_quiz,J-Weeks/blog_app,ga-wdi-boston/css-layout-positioning-08,ga-wdi-boston/wdi_7_js_demo_this,ga-wdi-boston/wdi_2_js_demo_spa,GAWDILessonRepos/MovieFrontEnd,ga-wdi-boston/wdi_2_js_handlebars_quiz,fishermanswharff/year-make-model-walkthrough,ga-wdi-boston/wdi_7_lab_jquery_todo,ga-wdi-b... | test/karma.conf.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar detector = (function(){\n\tfunction Filter(){\n\t\tthis.list = require('./lang.json').words;\n\t}\n\n\tFilter.prototype.isProfane = function isProfane(string){\n\t\tfor(var i = 0; i < this.list.length; i++)\n\t\t\tif(string.toLowerC... | javascript | edit | 0 | 4 | mit | 7b0190b0242d6d141d8a9f6016ef080f036db390 | ifross89/badwords,austinkelleher/badwords,web-mech/badwords | lib/badwords.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * Repository query\n */\nvar SavedQuery = Backbone.Model.extend({\n parse: function(response, XHR) {\n this.xml = response.xml;\n },\n \n url: function() {\n return encodeURI(Saiku.session.username + \"/r... | javascript | edit | 0 | 2 | apache-2.0 | 9a845c082d93ab04e91947b56c643a283dd4ab84 | bisone/saiku,bisone/saiku,bisone/saiku,bisone/saiku,bisone/saiku,bisone/saiku | js/saiku/models/Repository.js | rejected_duplicate | Near-duplicate of sample 72311 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n(function() {\n 'use strict';\n\n angular\n .module('davisCru')\n .config(config);\n\n /** @ngInject */\n function config($logProvider, envServiceProvider) {\n envServiceProvider.config({\n domains: {\n developm... | javascript | edit | 0 | 2 | mit | dffcabeb0b0d2ac452dd574ae781c48e5e33eb56 | daviscru/daviscru-website,daviscru/daviscru-website,OzzieOrca/DavisCru-AngularFire,OzzieOrca/DavisCru-AngularFire | src/app/index.config.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst jsdom = require('jsdom');\n\nglobal.document = jsdom.jsdom('<!doctype html><html><body><div></div></body></html>', {\n url: 'http://localhost',\n skipWindowCheck: true\n});\nglobal.window = document.defaultView;\nglobal.navigato... | javascript | edit | 0 | 0 | mit | 9d5a40d16d492e71617052ea95af6a3e5e20b042 | majakomel/WikiEduDashboard,feelfreelinux/WikiEduDashboard,sejalkhatri/WikiEduDashboard,Wowu/WikiEduDashboard,sejalkhatri/WikiEduDashboard,KarmaHater/WikiEduDashboard,MusikAnimal/WikiEduDashboard,Wowu/WikiEduDashboard,majakomel/WikiEduDashboard,alpha721/WikiEduDashboard,sejalkhatri/WikiEduDashboard,feelfreelinux/WikiEdu... | test/testHelper.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport PlayerController from './PlayerController'\nimport { connect } from 'react-redux'\nimport { requestPlayNext } from 'store/modules/status'\nimport {\n emitStatus,\n emitError,\n emitLeave,\n cancelStatus,\n mediaRequest,\n m... | javascript | edit | 0 | 2 | isc | bf77b83213d3d1e8be4b5b65d53484f4b4f19176 | bhj/karaoke-forever,bhj/karaoke-forever | src/routes/Player/components/PlayerController/PlayerControllerContainer.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\n/**\n * special handle in cluster\n */\nexport const master = {\n /**\n * get file by path\n */\n getFileByPath: (config, stc) => {\n let file = stc.resource.getFileByPath(config.file);\n return file.pathHis... | javascript | edit | 0 | 3 | mit | 3dc0acec0c6f5ab8c1f9254993e0d48ef600e524 | stcjs/stc | src/cluster_handle.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar exec = require('child_process').exec;\n\nmodule.exports = function(grunt) {\n\n grunt.initConfig({\n qunit: ['./test/index.html'],\n lint: ['supermodel.js', './test/*.js'],\n watch: {\n default: {\n files: ['su... | javascript | edit | 0 | 2 | mit | 2a601a3b34f099381468636bcaa8ab83457ee0d6 | pathable/supermodel,pathable/supermodel,TheBox193/supermodel,Gywem/supermodel,Gywem/supermodel,TheBox193/supermodel | grunt.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar express = require('express');\nvar router = express.Router();\n\n/* GET home page. */\nrouter.get('/', function(req, res) {\n res.render('index', { title: 'lists' });\n});\n\nrouter.get('/lists.json', function(req, res) {\n res.se... | javascript | edit | 0 | 1 | mit | 4dc2366abacd4c5cb31218e84659664f10d87f34 | nathansmyth/node-stack,nathansmyth/node-stack | routes/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\"use strict\";\n\ngetReplies(1)\n.then(function (replies) {\n return replies.filter(reply => !reply.isAbuse);\n})\n.then(function (filteredReplies) {\n console.log(filteredReplies);\n})\n```\n\nApply this change: Use cath to work wit... | javascript | edit | 0 | 1 | mit | 0880527e0384868d403730ae740065266c657302 | var-bin/reactjs-training,var-bin/reactjs-training,var-bin/reactjs-training | es2015/filter-replies.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar routes = (passport, mongoose) => {\n var express = require('express');\n var router = express.Router();\n\n router.get('/auth/github', passport.authenticate('github'));\n router.get('/auth/callback/github',\n passport.authent... | javascript | edit | 0 | 4 | unlicense | 3726a9a6adab2b7a55db9540cd4a2c2a68e88bc2 | treyhuffine/gitcoders | routes/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst db = require('georap-db');\nconst lib = require('./lib');\n\nmodule.exports = (params, callback) => {\n // Parameters:\n // params:\n // username\n // locationId\n // locationName\n // entryId\n // com... | javascript | edit | 0 | 1 | mit | f7ee3f7c5e9ad964276b94cbfb1ee831ce6865b0 | axelpale/tresdb,axelpale/tresdb | server/api/events/dal/commentRemoved.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nmodule(\"create-new\", {\n setup: function() {\n $('#qunit-fixture').append('<select id=\"organisation_govuk_status\" name=\"organisation_govuk_status\"><option value=\"closed\">Closed</option><option value=\"open\">Open</option></s... | javascript | edit | 0 | 1 | mit | 4a568906863d5f85b86103e01d6af3862369767e | askl56/whitehall,hotvulcan/whitehall,askl56/whitehall,robinwhittleton/whitehall,YOTOV-LIMITED/whitehall,YOTOV-LIMITED/whitehall,robinwhittleton/whitehall,ggoral/whitehall,alphagov/whitehall,alphagov/whitehall,ggoral/whitehall,askl56/whitehall,YOTOV-LIMITED/whitehall,alphagov/whitehall,ggoral/whitehall,alphagov/whitehal... | test/javascripts/unit/closed-organisation-hide-date_test.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nexport let declarationTypes = {\n CLASS: Symbol(),\n CLASS_METHOD: Symbol(),\n CLASS_ACCESSOR: Symbol(),\n OBJECT_LITERAL_METHOD: Symbol(),\n OBJECT_LITERAL_ACCESSOR: Symbol()\n};\n\nexport function getDeclarationType(args) {\n le... | javascript | edit | 0 | 7 | mit | e37508a8b694921b75d94d7c45628e087dc4a93e | lukehorvat/decorator-utils | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\n// base path, that will be used to resolve files and exclude\nbasePath = '.';\n\n// list of files / patterns to load in the browser\nfiles = [\n JASMINE,\n JASMINE_ADAPTER,\n 'misc/test-lib/jquery-1.8.2.min.js',\n 'misc/test-lib/a... | javascript | edit | 0 | 0 | mit | 3b5a3cca616ba60ce350e661aa78d4199874ae92 | realityking/ui-bootstrap,EnuygunCom/enuygun-frontend-vendor-ui-bootstrap,Lohann/bootstrap,gfaceless/bootstrap,eduncan26/bootstrap,ThePenguin1140/semantic-angular,kongx73/bootstrap,universsky/bootstrap-1,bqevin/bootstrap-1,dmc2015/bootstrap,filso/bootstrap,nathan-j-brenner/bootstrap-1,martin-brennan-csnet/bootstrap,nobi... | testacular.conf.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nlet Octokat = require('octokat');\nlet octo = new Octokat({});\n\nclass GithubApi {\n static testOctokat(){\n return new Promise((resolve) => {\n resolve(octo.repos('compumike08', 'GitHub_Status_API_GUI').fetch());\n });\n ... | javascript | edit | 0 | 1 | mit | 2197aa8a6246348070b9c26693ec08fc44f02031 | compumike08/GitHub_Status_API_GUI,compumike08/GitHub_Status_API_GUI | src/api/githubAPI.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nmodule.exports.rewire = function(module, autoReset, afterEachHook) {\n var rewiredNames = [];\n if (typeof autoReset === 'undefined') {\n autoReset = true;\n }\n if (typeof afterEachHook === 'undefined') {\n afterEachHook = af... | javascript | edit | 0 | 4 | mit | facd926c85afef860de9752518fe1af96f5dfc8d | rincedd/rewire-test-helper | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar AWS = require('aws-sdk');\nvar s3 = new AWS.S3();\nvar yaml = require('js-yaml');\n\n// const s3EnvVars = require('s3-env-vars');\n// var doc = s3EnvVars(\"mybucketname\", \"folderpathinbucket\", \"filename\", function(err, data) {\... | javascript | edit | 0 | 3 | mit | 7d804e27fe4f420e1437f36922a76da645d50249 | Referly/lambda-s3-yml | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nvar CSON = require('cson'),\n log = console.log.bind(console),\n DEFAULT_CONFIG_FILE = 'config.cson';\n\nvar loadConfig = function(configFileName) {\n configFileName = configFileName || DEFAULT_CONFIG_FILE;\n var co... | javascript | edit | 0 | 3 | mit | ba2b91002ae89cbb64cd4805391ed31870055c5e | mikemaccana/boring-config | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n(function() {\n\n // Baseline setup\n // --------------\n\n /** Used to determine if values are of the language type `Object` */\n var objectTypes = {\n 'function': true,\n 'object': true\n };\n\n // Establish the root objec... | javascript | edit | 0 | 4 | apache-2.0 | 33fda16138f67459dab826c6aa57c6efe9a4fecf | ariutta/cross-platform-shapes,ariutta/cross-platform-shapes | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nvar fs = require('fs');\n\n/**\n * Decorate docopt to extract doc from file.\n */\nfunction fdocopt(docopt) {\n docopt = docopt || require('docopt').docopt;\n\n return function (file, kwargs) {\n return docopt(extr... | javascript | edit | 0 | 2 | unlicense | f16c3136e77167b1cc766840630d036e08a6d9ef | valeriangalliat/fdocopt | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nangular.module('repicbro.services')\n .factory('PostsManager', function ($rootScope, Posts) {\n\n var posts = [],\n current = null,\n index = 0,\n latest = '',\n updating = false;\n\n ... | javascript | edit | 0 | 3 | mit | 977f41bda3d6ab779b8e55096ae730b603a504e7 | stinaq/repicbro.com,stinaq/repicbro.com | app/scripts/services/postsmanager.js | rejected_duplicate | Near-duplicate of sample 80270 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/*\n * Copyright 2015 The Closure Compiler Authors.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License ... | javascript | edit | 0 | 1 | apache-2.0 | 26c6123fc065c8be5f7c607ccab150d1ebe9ec50 | ChadKillingsworth/closure-compiler-npm,google/closure-compiler-npm,ChadKillingsworth/closure-compiler-npm,google/closure-compiler-npm | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\"use strict\";\n\nmodule.exports = {\n // location of Sqlite DB file\n Cache: `${process.cwd()}/themeparks.db`,\n // default time to cache any data\n DefaultCacheLength: 60 * 60 * 6, // 6 hours\n // default request timeo... | javascript | edit | 0 | 2 | mit | f7b83cf260cfb89607704beb2ddf4b99646dc44b | cubehouse/themeparks | lib/settings.js | rejected_duplicate | Near-duplicate of sample 76752 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\n/**\n * Dependencies.\n */\n\nvar phonetics;\n\nphonetics = require('soundex-code');\n\n/**\n * Define `soundex`.\n */\n\nfunction soundex() {}\n\n/**\n * Change handler\n *\n * @this {WordNode}\n */\n\nfunction onchang... | javascript | edit | 0 | 4 | mit | b1f5b9f627fec42d6365e8f5cc6d20be44487222 | wooorm/retext-soundex | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nexport default function (config) {\n const trimPrefix = (config && config.trimPrefix) || /^.*[/]/;\n return {\n name: 'preload-dynamic-imports',\n renderDynamicImport({ format, targetModuleId }) {\n if (fo... | javascript | edit | 0 | 3 | mit | be855c7290c0ba7260fcdd14f19c419d05d3dcfc | fastmail/overture | tooling/rollup/rollup-plugin-preload-dynamic-imports.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar app = angular.module(\"AdmissionsApp\");\n\napp.service(\"PasswordCheckService\", [\"$http\", function ($http) {\n var submitBaseUrl = \"http://admissions.vschool.io/api/part\";\n\n this.checkPassword = function (password, par... | javascript | edit | 0 | 1 | mit | f7445497f6b89efcc6d88c053e3fc5c0b03361d6 | bobziroll/admissions,bobziroll/admissions | app/services/passwordCheckService.js | rejected_duplicate | Near-duplicate of sample 76666 | 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-hot-loader',\n serverMiddleware: function (config){\n var lsReloader = require('./lib/hot-reloader')(config.options);\n lsReloader.run()... | javascript | edit | 0 | 4 | mit | d8c2432176cb64f2dcab315ebe6afcb62c6bc4e3 | toranb/ember-cli-hot-loader,toranb/ember-cli-hot-loader | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict'\n\nvar raven = require('raven')\n\nexports.register = function (server, options, next) {\n var client = new raven.Client(options.dsn, options.client)\n server.expose('client', client)\n server.on('request-error', functio... | javascript | edit | 0 | 1 | bsd-3-clause | 54f777018c2469fe864eed405c01670e76527ae2 | antonsamper/hapi-raven-boom,bendrucker/hapi-raven | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport React from 'react'\nimport ReactDOM from 'react-dom'\n\nclass MapContainer extends React.Component {\n\n render() {\n return (\n <div css={{\n display: 'flex',\n minHeight: '30em',\n }}>\n <ifra... | javascript | edit | 0 | 1 | mit | 26c76d3eb9b210a7692ae4a0d255f4fb9ad0ca18 | benruehl/gatsby-kruemelkiste | src/components/MapContainer.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nwindow.addEventListener(\"DOMContentLoaded\", function() {\n\n // get the form elements defined in your form HTML above\n\n var form = document.getElementById(\"my-form\");\n var button = document.getElementById(\"my-form-button\");\... | javascript | edit | 0 | 3 | mit | 41281b87bf0ee52c9f5b71b16f8013940652e01a | joshukraine/getbiblefirst.com,euroteamoutreach/getbiblefirst.com,euroteamoutreach/getbiblefirst.com,joshukraine/getbiblefirst.com,euroteamoutreach/getbiblefirst.com,joshukraine/getbiblefirst.com,joshukraine/getbiblefirst.com | source/assets/javascripts/_formspree.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\"use strict\"\n// System\nvar fs = require('fs')\n\n// 3rd Party\nvar template = require('lodash.template')\n\n// Rendering settings\nvar settings = {\n escape: /{-([\\s\\S]+?)-}/g,\n evaluate: /{%([\\s\\S]+?)%}/g,\n interpola... | javascript | edit | 0 | 2 | mit | ac2beab3c3391273230271509fa8c50ebe0f3440 | shakefu/template-js | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\ndescribe('idai field app', function() {\n\n it('should create a new object of type object ', function() {\n browser.get('/');\n\n element(by.id('object-overview-button-create-object')).click().then(function(){\n ... | javascript | edit | 0 | 1 | apache-2.0 | 099de60a9c7e9d94eca5401d81a6e6d81eb793c5 | codarchlab/idai-field-client,codarchlab/idai-field-client,codarchlab/idai-field-client,codarchlab/idai-field-client | src/e2e/basic-scenarios.spec.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nfunction setWindowSizeOverride(width, height) {\n if (window.internals)\n window.internals.settings.setTextAutosizingWindowSizeOverride(width, height);\n}\n\nfunction setFontScaleFactor(scale) {\n if (window.internals)\n ... | javascript | edit | 0 | 4 | bsd-3-clause | db28cfacf5d41564920dcb351a403809179d87cf | PeterWangIntel/blink-crosswalk,PeterWangIntel/blink-crosswalk,smishenk/blink-crosswalk,PeterWangIntel/blink-crosswalk,PeterWangIntel/blink-crosswalk,XiaosongWei/blink-crosswalk,smishenk/blink-crosswalk,PeterWangIntel/blink-crosswalk,XiaosongWei/blink-crosswalk,Bysmyyr/blink-crosswalk,Bysmyyr/blink-crosswalk,PeterWangIn... | LayoutTests/fast/text-autosizing/resources/autosizingTest.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst assert = require('assert')\nconst fs = require('fs')\nconst path = require('path')\n\nconst GitHub = require('../../src/models/github')\n\ndescribe('GitHub', () => {\n describe('getToken', () => {\n it('returns contents of .en... | javascript | edit | 0 | 1 | mit | a33618fa48c31a8d251562d8f47d38933a2ea443 | cheshire137/gh-notifications-snoozer,cheshire137/gh-notifications-snoozer | test/models/github-test.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar MonitoringPlugin = function() {\n\n};\n\nMonitoringPlugin.prototype.init = function(rcl, wflib, engine) {\n this.rcl = rcl;\n this.wflib = wflib;\n this.engine = engine;\n\n console.log(\"Hello world!\");\n};\n\nmodule.e... | javascript | edit | 0 | 3 | mit | 5afb65dc83975010952c38dd52eb6b1ce06a0320 | dice-cyfronet/hyperflow-monitoring-plugin | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nconst chai = require('chai')\nconst expect = chai.expect\n\nconst path = require('path')\nconst kpio = require('keepass.io')\n\ndescribe('keePass', () => {\n it('should unlock support team KeePass file with photo of readheaded call cen... | javascript | edit | 0 | 1 | mit | bb7496c8ae49876a112018d0aed6af7828891d82 | bkimminich/juice-shop,bkimminich/juice-shop,bkimminich/juice-shop,bkimminich/juice-shop,bkimminich/juice-shop,bkimminich/juice-shop | test/server/keePassSpec.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n#!/usr/bin/env node\n'use strict';\nconst Promise = require('pinkie-promise');\nconst Xray = require('x-ray'), xray = Xray();\nconst cli = require('./cli');\n\nconst getUsrPkgs = function(username) {\n return new Promise(function(resol... | javascript | edit | 0 | 3 | mit | f6a48dfd9e61dae068f40c32988f5ce6882693bd | kshvmdn/pkg-stats | index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n\n/**\n * TwitterClient.js\n * Twitterをbotが利用しやすいようにwrapしたもの\n */\n\nconst TwitterClient = class {\n constructor (twitter) {\n this.twitter = twitter\n }\n\n /**\n * UserStreamのlistenを開始する\n * @param {object} on コールバック関数を格納したオ... | javascript | edit | 0 | 1 | mit | ae409636932f80dc8aa34de4189242b08a413198 | 3x10ce/398bot | src/TwitterClient.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/*\nLanguage: Test Anything Protocol\nRequires: yaml.js\nAuthor: Sergey Bronnikov <<EMAIL>>\nWebsite: https://bronevichok.ru/\n*/\n\nfunction(hljs) {\n return {\n aliases: ['TAP'],\n case_insensitive: true,\n contains: [\n ... | javascript | edit | 0 | 1 | bsd-3-clause | 878e41b5c861c1fa3f170c976ec34ca2410e0745 | highlightjs/highlight.js,lead-auth/highlight.js,isagalaev/highlight.js,sourrust/highlight.js,highlightjs/highlight.js,Sannis/highlight.js,isagalaev/highlight.js,carlokok/highlight.js,MakeNowJust/highlight.js,palmin/highlight.js,Sannis/highlight.js,carlokok/highlight.js,highlightjs/highlight.js,StanislawSwierc/highlight... | src/languages/tap.js | rejected_duplicate | Near-duplicate of sample 89847 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar appInsights=window.appInsights||function(config){\nfunction r(config){t[config]=function(){var i=arguments;t.queue.push(function(){t[config].apply(t,i)})}}var t={config:config},u=document,e=window,o=\"script\",s=u.createElement(o),i... | javascript | edit | 0 | 5 | mit | 24cc35e57d62d2b39b521b58fa4891c56ef82848 | jguadagno/intro-to-bootstrap,jguadagno/intro-to-bootstrap | js/ai.js | rejected_duplicate | Near-duplicate of sample 78999 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar path = require('path');\n\nmodule.exports = exports = function defaultConfig(ccaRoot) {\n return {\n plugin_search_path: [\n path.join(ccaRoot, 'cordova'),\n path.join(ccaRoot, 'cordova', 'cordova-plugins'),\n ... | javascript | edit | 0 | 1 | bsd-3-clause | 537fc555a74185c2d90c85b99123e4acac249c0e | hgl888/mobile-chrome-apps,hgl888/mobile-chrome-apps,xiaoyanit/mobile-chrome-apps,wudkj/mobile-chrome-apps,hgl888/mobile-chrome-apps,MobileChromeApps/mobile-chrome-apps,liqingzhu/mobile-chrome-apps,hgl888/mobile-chrome-apps,chirilo/mobile-chrome-apps,xiaoyanit/mobile-chrome-apps,chirilo/mobile-chrome-apps,hgl888/mobile-... | src/default-config.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n// @flow\n\nimport invariant from 'invariant';\nimport { Platform } from 'react-native';\n\nconst productionServer = 'https://squadcal.org';\nconst localhostServer = 'http://localhost/squadcal';\nconst localhostServerFromAndroidEmulator... | javascript | edit | 0 | 4 | bsd-3-clause | 48e6c28f548f4c041db40c3f9fb0f7e114e76700 | Ashoat/squadcal,Ashoat/squadcal,Ashoat/squadcal,Ashoat/squadcal,Ashoat/squadcal,Ashoat/squadcal,Ashoat/squadcal | native/utils/url-utils.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nvar svgNS = \"http://www.w3.org/2000/svg\";\nvar xlinkNS = \"http://www.w3.org/1999/xlink\";\n\nvar rootSVGElement;\n\nfunction createSVGElement(name) {\n return document.createElementNS(svgNS, \"svg:\" + name);\n}\n\nfunction create... | javascript | edit | 0 | 2 | bsd-3-clause | cb5855a1e306a2e40314ee7f749c1800496e5e4a | ondra-novak/blink,Pluto-tv/blink-crosswalk,crosswalk-project/blink-crosswalk-efl,smishenk/blink-crosswalk,kurli/blink-crosswalk,modulexcite/blink,kurli/blink-crosswalk,smishenk/blink-crosswalk,jtg-gg/blink,XiaosongWei/blink-crosswalk,kurli/blink-crosswalk,nwjs/blink,modulexcite/blink,crosswalk-project/blink-crosswalk-e... | LayoutTests/svg/dynamic-updates/resources/SVGTestCase.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n// Saves options to chrome.storage\ndocument.addEventListener(\"DOMContentLoaded\", function() {\n document.addEventListener('DOMContentLoaded', restore_options);\n document.getElementById('token-form').addEventListener('submit', ... | javascript | edit | 0 | 2 | isc | 24530908bdbe322cfe5f1bdd22bb1f555cbf88d0 | oliverswitzer/wwltw-for-pivotal-tracker,oliverswitzer/wwltw-for-pivotal-tracker | src/options/index.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * Firefox proxy settings implementation\n * TODO(salomegeo): rewrite it in typescript\n */\n\nvar prefsvc = require(\"sdk/preferences/service\");\n\nvar proxyConfig = function() {\n this.running_ = false;\n};\n\nproxyConfig.start... | javascript | edit | 0 | 2 | apache-2.0 | 73e2297e04aeef69f2b53e6876d07f59ad38dfcb | chinarustin/uproxy,dhkong88/uproxy,MinFu/uproxy,itplanes/uproxy,jpevarnek/uproxy,qida/uproxy,IveWong/uproxy,chinarustin/uproxy,chinarustin/uproxy,uProxy/uproxy,roceys/uproxy,jpevarnek/uproxy,uProxy/uproxy,chinarustin/uproxy,MinFu/uproxy,jpevarnek/uproxy,IveWong/uproxy,MinFu/uproxy,itplanes/uproxy,uProxy/uproxy,chinarus... | src/firefox/lib/firefox_proxy_config.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport mongoose from 'mongoose';\nimport { ImageSchema } from 'src/models/ImageModel';\nimport { ThumbnailSchema } from 'src/models/ThumbnailModel';\n\nconst { Schema } = mongoose;\n\nexport const PostSchema = new Schema({\n title: {\n... | javascript | edit | 0 | 2 | mit | adf0755ed974d27e0f019275367b30894b0cd838 | tuelsch/bolg,tuelsch/bolg | src/models/PostModel.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nimport 'angular';\n\nexport default [function () {\n return {\n restrict: 'E',\n transclude: true,\n replace: true,\n templateUrl: '/modules/ui-kit/sol-tabs/sol-tabs.html',\n scope: {\n s... | javascript | edit | 0 | 3 | mit | bd200839854cd7090bcdf2e5388f6033de02477d | sanbiv/solarizd,Tudmotu/solarizd,Tudmotu/solarizd,Tudmotu/solarizd,sanbiv/solarizd | src/modules/ui-kit/sol-tabs/sol-tabs.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\nlet tpl = `\n<h2>{{selectedDomain}}</h2>\n\n<ul>\n {{#results}}\n <li>\n <a href=\"/mirrorjson/{{../selectedDomain}}/{{hash}}\"{{#if path}} title=\"{{path}}\"{{/if}}>{{hash}}</a>\n =>\n {{json}... | javascript | edit | 0 | 1 | mit | fc234a934deb662cf33be88886cc1b22555284f1 | makingwaves/mirrorjson,makingwaves/mirrorjson | templates/elementslist.handlebars.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/* global Vulcan */\nimport { Comments } from '../../lib/collections/comments'\nimport { Posts } from '../../lib/collections/posts'\nimport { wrapVulcanAsyncScript } from '../scripts/utils'\nimport { batchUpdateScore } from '../../lib/m... | javascript | edit | 0 | 1 | mit | f4c6abfc533aa3d2b01162aa50798e02b4a3dabf | Discordius/Lesswrong2,Discordius/Lesswrong2,Discordius/Telescope,Discordius/Lesswrong2,Discordius/Telescope,Discordius/Lesswrong2,Discordius/Telescope,Discordius/Telescope | packages/lesswrong/server/database-import/force_batch_update_scores.js | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n/**\n * Assigns a rank to an operator. Ranks are assigned in increasing order\n * by incrementing an internal rank counter.\n * @param {Operator} op - The operator to assign a rank.\n */\nexport function rank(op) {\n op.rank = ++this._... | javascript | edit | 0 | 5 | bsd-3-clause | 63ceac0328a8e368c911afab2ca3f9a6da3651c0 | lgrammel/vega,vega/vega,vega/vega,vega/vega,vega/vega | packages/vega-dataflow/src/dataflow/rank.js | rejected_duplicate | Near-duplicate of sample 83348 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\napp.controller('MyIndexController', ['$scope', function ($scope) {\n $scope.searchTable = false;\n $scope.files = [];\n $scope.searchFiles = [];\n $scope.instance = new Index();\n $scope.showIndex = false;\n $scope.showSearch = fa... | javascript | edit | 0 | 1 | mit | 892d419410649c1853333d0ec21f656185083258 | andela-pbirir/inverted-index,andela-pbirir/inverted-index | src/js/controllers/MyIndexController.js | rejected_duplicate | Near-duplicate of sample 79889 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```javascript\n'use strict';\n\nconst config = require(`${__dirname}/../config/init`);\n\n/**\n * makeAllRowRequestBody(str)\n * @param string field Field to query parameters from.\n * @param string from Date to query results from.\n * @param string t... | javascript | edit | 0 | 1 | apache-2.0 | 10b05e9cb32145bb358cfb4e9ac58b5d995589be | seestats/api | helpers/requestHelper.js | rejected_duplicate | Near-duplicate of sample 76364 | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.