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```typescript\nimport { Cell } from './Cell'\nimport { Settings } from './Settings'\n\nexport class Grid {\n private constructor() {\n for (let rowIndex = 0; rowIndex < Settings.instance.rows; rowIndex++) {\n for (let columnIndex = 0; columnI... | typescript | edit | 0 | 1 | mit | cabaffbc473f9a8c133f5d3d7f749a3cc3e5a7e4 | janaagaard75/desert-walk,janaagaard75/desert-walk | src/model/Grid.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { AppComponent } from './app.component';\nimport { AppModule } from './app.module';\nimport { HspApiService } from './hsp-api.service';\nimport { ResourceService } from './national_rail/resource.service';\n\nimport { async, Compo... | typescript | edit | 0 | 1 | mit | cfc03b7e6e0d87665ad95d70cc151d75d2fcb4fc | briggySmalls/late-train-mate,briggySmalls/late-train-mate,briggySmalls/late-train-mate | src/app/app.component.spec.ts | rejected_duplicate | Near-duplicate of sample 115083 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { IFeedbackCESForm } from 'component/feedback/FeedbackCES/FeedbackCESForm';\n\ninterface IFeedbackEndpointRequestBody {\n source: 'app' | 'app:segments';\n data: {\n score: number;\n comment?: string;\n ... | typescript | edit | 0 | 2 | apache-2.0 | 29e7fbbcaea54ebdd62691e71bcd262f079c8e96 | Unleash/unleash-frontend,Unleash/unleash-frontend,Unleash/unleash-frontend,Unleash/unleash-frontend | src/component/feedback/FeedbackCES/sendFeedbackInput.ts | rejected_duplicate | Near-duplicate of sample 115172 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport {Component, EventEmitter, Input, Output} from '@angular/core';\nimport {HsHistoryListService} from '../../../common/history-list/history-list.service';\n\n@Component({\n selector: 'hs-add-data-common-url',\n templateUrl: './add... | typescript | edit | 0 | 1 | mit | 402133ad4944da0f11d69595f159bb7a3d52b05d | hslayers/hslayers-ng,hslayers/hslayers-ng,hslayers/hslayers-ng,hslayers/hslayers-ng | projects/hslayers/src/components/add-data/common/add-data-url.component.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for ... | typescript | edit | 0 | 0 | mit | 8572664c6c7674c31750d94754c6e1309251fe10 | eamodio/vscode,Microsoft/vscode,microsoft/vscode,Krzysztof-Cieslak/vscode,eamodio/vscode,Microsoft/vscode,eamodio/vscode,Microsoft/vscode,microsoft/vscode,microsoft/vscode,Microsoft/vscode,microsoft/vscode,eamodio/vscode,Krzysztof-Cieslak/vscode,eamodio/vscode,eamodio/vscode,microsoft/vscode,eamodio/vscode,microsoft/vs... | extensions/typescript-language-features/src/utils/fileSchemes.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { spawn } from 'child_process'\nimport { platform } from 'os'\n\nclass Command {\n public name: string\n public args: string[]\n}\n\n/** Opens a shell setting the working directory to fullpath. If a shell is not specified, OS d... | typescript | edit | 0 | 5 | mit | e0e08b61a2b7544147621e5b58d0f11ec8d2862e | artivilla/desktop,gengjiawen/desktop,artivilla/desktop,kactus-io/kactus,shiftkey/desktop,say25/desktop,desktop/desktop,BugTesterTest/desktops,desktop/desktop,BugTesterTest/desktops,BugTesterTest/desktops,hjobrien/desktop,kactus-io/kactus,BugTesterTest/desktops,shiftkey/desktop,j-f1/forked-desktop,gengjiawen/desktop,j-f... | app/src/lib/open-shell.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { FC, createElement as h } from 'react';\nimport { PageProps } from '@not-govuk/app-composer';\nimport { Page } from '@hods/components';\n\nimport './app.scss';\n\nexport const PageWrap: FC<PageProps> = ({ children }) => {\n con... | typescript | edit | null | null | mit | c0effc11163ea16d8213613deeed44f911e9aeb1 | eliothill/home-office-digital-patterns,eliothill/home-office-digital-patterns,eliothill/home-office-digital-patterns | apps/docs/src/common/page-wrap.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for ... | typescript | edit | 0 | 0 | mit | 7e4efa6aa078c651afc07a381632c5999dde8d45 | eamodio/vscode,microsoft/vscode,eamodio/vscode,microsoft/vscode,eamodio/vscode,microsoft/vscode,microsoft/vscode,microsoft/vscode,microsoft/vscode,microsoft/vscode,eamodio/vscode,eamodio/vscode,eamodio/vscode,eamodio/vscode,eamodio/vscode,eamodio/vscode,microsoft/vscode,microsoft/vscode,eamodio/vscode,microsoft/vscode,... | src/vs/workbench/contrib/terminal/common/terminalExtensionPoints.contribution.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n// Enum for the kind of map\nexport type MapType = City | Square;\ninterface City { kind: \"city\"; }\ninterface Square { kind: \"square\"; }\n\n// Map class\nexport class Map {\n constructor(\n private id: number,\n private heig... | typescript | edit | 0 | 1 | mit | 94dc3a736e7868c53e0348c8c916564e74c32683 | ABAPlan/abaplan-core,ABAPlan/abaplan-core,ABAPlan/abaplan-core | app/core/map.ts | rejected_duplicate | Near-duplicate of sample 114052 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for ... | typescript | edit | 0 | 4 | mit | c310e402216b17450add3111c0fa986a4b421819 | microsoft/vscode,Krzysztof-Cieslak/vscode,Krzysztof-Cieslak/vscode,microsoft/vscode,eamodio/vscode,Krzysztof-Cieslak/vscode,microsoft/vscode,eamodio/vscode,Krzysztof-Cieslak/vscode,Microsoft/vscode,Krzysztof-Cieslak/vscode,microsoft/vscode,Microsoft/vscode,microsoft/vscode,microsoft/vscode,Krzysztof-Cieslak/vscode,Krzy... | src/vs/workbench/contrib/webview/electron-browser/webviewCommands.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport * as React from \"react\";\n\nimport Highlighter from \"../syntax-highlighter\";\n\nexport type SourceProps = {\n language: string;\n children: React.ReactNode[];\n className: string;\n theme: \"light\" | \"dark\";\n};\n\nexp... | typescript | edit | null | null | bsd-3-clause | 7227ca7449fbfea85b662ef7847c2ba2f135d832 | nteract/nteract,nteract/composition,nteract/composition,nteract/nteract,nteract/composition,nteract/nteract,nteract/nteract,nteract/nteract | packages/presentational-components/src/components/source.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/*---------------------------------------------------------------------------------------------\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License. See License.txt in the project root for ... | typescript | edit | 0 | 4 | mit | a8e37a4b43398363fbe832bc47e5314853be96a9 | eamodio/vscode,eamodio/vscode,microsoft/vscode,microsoft/vscode,microsoft/vscode,eamodio/vscode,microsoft/vscode,eamodio/vscode,microsoft/vscode,microsoft/vscode,eamodio/vscode,microsoft/vscode,eamodio/vscode,eamodio/vscode,eamodio/vscode,eamodio/vscode,eamodio/vscode,microsoft/vscode,microsoft/vscode,microsoft/vscode,... | src/vs/platform/extensions/electron-main/directMainProcessExtensionHostStarter.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { BehaviorSubject } from \"rxjs/BehaviorSubject\";\nimport { Observable } from \"rxjs/Observable\";\n\nimport { Token } from \"./token\";\nimport { TokenStorage } from \"./token-storage\";\n\nexport abstract class AbstractTokenSt... | typescript | edit | 0 | 3 | mit | 2f886fff844ccf9b1ff3358f89555bb1e28fd5e8 | cookingfox/stibble-api-client-angular,cookingfox/stibble-api-client-angular,cookingfox/stibble-api-client-angular | src/token/abstract-token-storage.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { CommonModule } from '@angular/common';\nimport { FormsModule } from '@angular/forms';\nimport { ItemPipe } from './pipes/item.pipe';\nimport { ModuleWithProviders, NgModule } from '@angular/core';\nimport { OffClickDirective } ... | typescript | edit | 0 | 1 | mit | 55e324044ba20b8292e1365003aefad034325501 | Crazyht/crazy-select,Crazyht/ngx-tree-select,Crazyht/ngx-tree-select,Crazyht/crazy-select,Crazyht/ngx-tree-select,Crazyht/crazy-select | src/ngx-tree-select/src/module.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { useCallback } from 'react';\nimport { Organization } from '@proton/shared/lib/interfaces';\nimport { FREE_ORGANIZATION } from '@proton/shared/lib/constants';\nimport { OrganizationModel } from '@proton/shared/lib/models/organiz... | typescript | edit | 0 | 2 | mit | 4ad88f935cd1440e101c47644ed55c4e38afc117 | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | packages/components/hooks/useOrganization.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { selectors } from \"@nteract/core\";\r\nimport { mockAppState } from \"@nteract/fixtures\";\r\n\r\nimport { makeMapStateToProps } from \"../../src/inputs/editor\";\r\n\r\ndescribe(\"makeMapStateToProps\", () => {\r\n it(\"retur... | typescript | edit | null | null | bsd-3-clause | b5dced02027577ac4ff5773290bfd5053da03280 | nteract/nteract,nteract/nteract,nteract/composition,nteract/nteract,nteract/nteract,nteract/composition,nteract/composition,nteract/nteract | packages/stateful-components/__tests__/inputs/editor.spec.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { HardwareTextureWrapper } from '../../Materials/Textures/hardwareTextureWrapper';\r\nimport { Nullable } from '../../types';\r\nimport * as WebGPUConstants from './webgpuConstants';\r\n\r\n/** @hidden */\r\nexport class WebGPUHa... | typescript | edit | 0 | 1 | apache-2.0 | 579c8c20d48bb5288724d755eae0a9dd94b88ef5 | NicolasBuecher/Babylon.js,NicolasBuecher/Babylon.js,sebavan/Babylon.js,Kesshi/Babylon.js,RaananW/Babylon.js,sebavan/Babylon.js,Kesshi/Babylon.js,NicolasBuecher/Babylon.js,BabylonJS/Babylon.js,RaananW/Babylon.js,RaananW/Babylon.js,Kesshi/Babylon.js,BabylonJS/Babylon.js,sebavan/Babylon.js,BabylonJS/Babylon.js | src/Engines/WebGPU/webgpuHardwareTexture.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { FunctionComponent, useEffect } from 'react';\nimport { useDispatch } from 'react-redux';\n\nimport { SERVICE_PROVIDERS_GRID } from '@waldur/marketplace/offerings/service-providers/constants';\nimport Grid from '@waldur/marketpl... | typescript | edit | null | null | mit | 71a02408291654f5a810e7b6409a051b978bcbae | opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport | src/marketplace/offerings/service-providers/ServiceProvidersGrid.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/// <reference path=\"../../../node_modules/typescript/lib/lib.webworker.d.ts\" />\n\nimport { ClearMessage, DisplayMessage, InputType } from '../messages'\nimport { State } from './state'\nimport { stringToUtf8ByteArray } from '../util... | typescript | edit | 0 | 5 | mit | 9d1fcb8ccf18102dafca47d5b1a28a765ea4bb49 | Alexendoo/utf,Alexendoo/utf,Alexendoo/utf,Alexendoo/utf | src/ts/worker/senders.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport TrezorConnect from 'trezor-connect';\nimport { logger } from '../utils/logging';\nimport { manifest } from './manifest';\n\nexport const initTrezorConnect = async () => {\n try {\n await TrezorConnect.init({\n popup: fal... | typescript | edit | 0 | 2 | apache-2.0 | bb3b93fa0473504db53b5fc135ea855a2e8946d5 | input-output-hk/daedalus,input-output-hk/daedalus,input-output-hk/daedalus,input-output-hk/daedalus,input-output-hk/daedalus,input-output-hk/daedalus | source/main/trezor/connection.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { NgModule } from '@angular/core';\nimport { BrowserModule } from '@angular/platform-browser';\nimport { FormsModule } from '@angular/forms';\n\nimport { CalendarComponent } from './calendar.component';\n\n@NgModule({\n declarat... | typescript | edit | 0 | 0 | mit | aa0707fa2775d9c07858046245c0d6f0280828cd | swimlane/ngx-ui,swimlane/ngx-ui,Hypercubed/ngx-ui,swimlane/ngx-ui,Hypercubed/ngx-ui,Hypercubed/ngx-ui,Hypercubed/ngx-ui,swimlane/ngx-ui | src/components/calendar/calendar.module.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport React from 'react'\nimport {DiffComponent, ReferenceDiff} from '../../../diff'\nimport {Change} from '../../../diff/components'\nimport {ReferencePreview} from '../preview/ReferencePreview'\n\nexport const ReferenceFieldDiff: Dif... | typescript | edit | null | null | mit | 5617f1bac1cc33055ef4854591a5513858493157 | sanity-io/sanity,sanity-io/sanity,sanity-io/sanity,sanity-io/sanity | packages/@sanity/field/src/types/reference/diff/ReferenceFieldDiff.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { IStream } from \"../../src/stream/stream.i\";\n\nexport class StreamBuilder {\n\n public build(): IStream {\n return <IStream> {\n writeLine: (message: string) => { }\n };\n }\n\n}\n\n```\n\nApply... | typescript | edit | 0 | 1 | mit | 43d671dc661a23df2da41f93e5a6c7c5784b0cac | alsatian-test/tap-bark,alsatian-test/tap-bark | test/_builders/stream-builder.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { FastRateLimit } from 'fast-ratelimit';\n\nconst limit = new FastRateLimit({ // $type: FastRateLimit\n threshold: 20,\n ttl: 60,\n});\n\nconst someNamespace = 'some-namespace';\n\nconst consume = limit.consume(someNamespac... | typescript | edit | 0 | 1 | mit | 5741a4ff4ebf7c1a92f6374ba4334540beddba9e | dsebastien/DefinitelyTyped,mcliment/DefinitelyTyped,dsebastien/DefinitelyTyped,borisyankov/DefinitelyTyped,georgemarshall/DefinitelyTyped,georgemarshall/DefinitelyTyped,markogresak/DefinitelyTyped,georgemarshall/DefinitelyTyped,georgemarshall/DefinitelyTyped,borisyankov/DefinitelyTyped | types/fast-ratelimit/fast-ratelimit-tests.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport App from './app.js';\n\nReactDOM.render(\n <App />,\n document.getElementById('appContainer')\n);\nconsole.log(App)\n```\n\nApply this change: Update example to act... | typescript | edit | null | null | mit | 5a32a070c4ea6852d40fcdb55afa78cd7f0fa1ff | TypeStrong/ts-loader,jbrantly/ts-loader,jbrantly/ts-loader,jbrantly/ts-loader,TypeStrong/ts-loader | examples/react-babel-allowjs/src/main.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport * as fs from 'fs';\nimport * as path from 'path';\nimport { Definition } from '../../src/components/definition';\n\nconst configs = require('../configs.json');\n\nconst cwd = process.cwd();\n\nexport type Logger = (data: LoggerDa... | typescript | edit | 0 | 3 | mit | 4ef928ca86b88b22b88295815e3f4812540fcf9f | ikatyang/types-ramda,ikatyang/types-ramda | scripts/utils/generateTypings.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { Rest } from '../RestHelpers/rest';\n\n/**\n * interface for callback\n * @interface IAuthStateCallback \n */\nexport interface IAuthStateCallback { (state: string): void; }\n\n/**\n * Connects to user database\n * @class Auth\n... | typescript | edit | 0 | 2 | mit | e12ae55aa7ab192b262a0c2ad4f017af1cc3c740 | annich-MS/OutlookVSTS,annich-MS/OutlookVSTS,annich-MS/OutlookVSTS | src/client/VSTS/authMM.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { c } from 'ttag';\n\nimport useToolbarActions from '../../../../hooks/drive/useActions';\nimport { FileBrowserItem } from '../../../FileBrowser';\nimport { ContextMenuButton } from '../../ContextMenu';\n\ninterface Props {\n ... | typescript | edit | null | null | mit | 0d502b78d4916fe983aba6bee0be66b55951a62f | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | applications/drive/src/app/components/sections/SharedLinks/ContextMenuButtons/StopSharingButton.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nexport class App {\n\n private _events: Object;\n public start;\n public h;\n public createElement;\n\n constructor() {\n this._events = {};\n }\n\n on(name: string, fn: (...args) => void, options: any = {}) {\n if (options... | typescript | edit | 0 | 5 | mit | 7fc647fe64b53e2802e8950ce9a70c36b14c263c | yysun/apprun,yysun/apprun,yysun/apprun | app.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n// Type definitions for get-caller-file 1.0\n// Project: https://github.com/stefanpenner/get-caller-file#readme\n// Definitions by: Klaus Meinhardt <https://github.com/ajafff>\n// Definitions: https://github.com/DefinitelyTyped/Definite... | typescript | edit | 0 | 0 | mit | 86e85fd0e0e69e887ca75c1d8ab3650d9b66e8d8 | chrootsu/DefinitelyTyped,AgentME/DefinitelyTyped,arusakov/DefinitelyTyped,one-pieces/DefinitelyTyped,georgemarshall/DefinitelyTyped,markogresak/DefinitelyTyped,AgentME/DefinitelyTyped,dsebastien/DefinitelyTyped,rolandzwaga/DefinitelyTyped,laurentiustamate94/DefinitelyTyped,georgemarshall/DefinitelyTyped,dsebastien/Defi... | types/get-caller-file/index.d.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nexport class MongooseChartOptions {\n\n // NOTE: Fields are public since they should match ng-chart2 library naming \n // link: https://github.com/valor-software/ng2-charts\n public scaleShowVerticalLines: boolean = false;\n ... | typescript | edit | 0 | 1 | mit | dd80f53b1f8bab81a7fc083ce486e2520df2f584 | emc-mongoose/console,emc-mongoose/console,emc-mongoose/console | console/src/app/core/models/chart/mongoose-chart-interface/mongoose-chart-options.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/**\n * Copyright 2020 Google LLC\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 at\n *\n * https... | typescript | edit | 0 | 1 | apache-2.0 | 58defee7e6bbf1d85d0743c382d2c88d8db72eac | google/ground-platform,google/ground-platform,google/ground-platform,google/ground-platform | web-ng/src/app/components/project-header/project-header.component.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport 'colors'\n\nimport path = require('path')\nimport ts = require('typescript')\nimport { LanguageService } from './language-service'\nimport { writeFile } from './file-util'\nimport { logEmitted, logError } from './logger'\n\nexpor... | typescript | edit | 0 | 3 | mit | f010aec5620f5e339c35f3430b1cd438e3726d16 | ktsn/vuetype,ktsn/vuetype | src/lib/generate.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { SearchPage } from './search.po';\nimport {browser} from 'protractor';\n\ndescribe('ngAuction search', () => {\n let searchPage: SearchPage;\n\n beforeEach(() => {\n searchPage = new SearchPage();\n });\n\n it('should per... | typescript | edit | 0 | 1 | mit | 9a783c27e74169e85cc6d1974d0ab09f0c52b80d | Farata/angulartypescript,Farata/angulartypescript,Farata/angulartypescript | code-samples/Angular6/chapter14/ng-auction/client/e2e/search.e2e-spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n// Copyright 2021 Google LLC\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 at\n// \n// https:... | typescript | edit | 0 | 1 | apache-2.0 | bc3256d2e9622a640a0373f63f6155be120d49cb | google/zx,google/zx | index.d.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n\nimport { NativeCryptoKey } from \"webcrypto-core\";\nimport { CryptoKey } from \"./key\";\n\nexport class WrappedNativeCryptoKey extends CryptoKey {\n\n constructor(\n algorithm: KeyAlgorithm,\n extractable: boolean,\n type:... | typescript | edit | 0 | 1 | mit | 60d1d112cfcb958e99369d06eba8aea1148c8444 | PeculiarVentures/webcrypto-liner,PeculiarVentures/webcrypto-liner | src/wrapped_native_key.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/*\n * @license\n * Copyright Hôpitaux Universitaires de Genève. All Rights Reserved.\n *\n * Use of this source code is governed by an Apache-2.0 license that can be\n * found in the LICENSE file at https://github.com/DSI-HUG/dejaj... | typescript | edit | 0 | 1 | apache-2.0 | 83e3632b527bd5bf7451e7c29257cef702b2fe9b | DSI-HUG/dejajs-components,DSI-HUG/dejajs-components,DSI-HUG/dejajs-components,DSI-HUG/dejajs-components | demo/app/color-selector/color-selector-demo.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\ndeclare let google;\n\nimport { Event, IEvent } from \"../utils/event\";\n\nexport class GeocoderModule\n{\n\tonResult = new Event<any>();\n\n\tgeocodeAddress( address, callbackComplete?, callbackFail? ) {\n\n\t\tconsole.log(\"geocode a... | typescript | edit | 0 | 4 | mit | 816ff80db7d51f79009d67635541bac32451afa1 | Biopenlandes/PagesVertes,Biopenlandes/PagesVertes,Biopenlandes/PagesVertes | src/front-end/js/directory/modules/geocoder.module.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/**\n * Created by rtorres on 9/25/16.\n */\n\n\nexport function getCookie(cname: string): string {\n let name: string = cname + '=';\n let ca: string[] = document.cookie.split(';');\n for(var i = 0; i <ca.length; i++) {\n ... | typescript | edit | 0 | 1 | mit | 3f280d297b548c6108602d1f4069808c8aafe9fa | rafasis1986/EngineeringMidLevel,rafasis1986/EngineeringMidLevel,rafasis1986/EngineeringMidLevel,rafasis1986/EngineeringMidLevel,rafasis1986/EngineeringMidLevel | knockoutapp/app/services/utils.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { DEBUG } from '@glimmer/env';\nimport { ComponentManager, ComponentCapabilities, TemplateArgs } from '@glimmer/core';\nimport BaseComponent, { ARGS_SET } from './component';\n\nexport interface Constructor<T> {\n new (owner: un... | typescript | edit | 0 | 2 | mit | b732c0ce444728b4d0f2386f34784741414d921d | glimmerjs/glimmer.js,glimmerjs/glimmer.js,glimmerjs/glimmer.js,glimmerjs/glimmer.js | packages/@glimmer/component/addon/-private/base-component-manager.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport React, { useState, useEffect } from 'react';\nimport { useParams } from 'react-router-dom';\nimport { search } from './search';\nimport DocumentTeaser from './DocumentTeaser';\nimport { Container, Row, Col } from 'react-bootstrap... | typescript | edit | null | null | apache-2.0 | e52551931440101f6204151d6f8ae165bb3b7559 | dainst/idai-field-web,dainst/idai-field-web,dainst/idai-field-web | ui/src/Project.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport {\n Component,\n OnInit,\n Input,\n Output,\n EventEmitter,\n NgZone} from '@angular/core';\n\n@Component({\n selector: 're-captcha',\n template: '<div class=\"g-recaptcha\" [attr.data-sitekey]=\"site_key\... | typescript | edit | 0 | 2 | isc | 12e888b4668a250e00f9a30ed8d5856d0f76c66b | xmaestro/angular2-recaptcha | components/captcha.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport * as assert from \"assert\";\nimport {getInfoFromString} from \"./../../../main\";\n\nconst code =\n`interface MyInterface {\n myString: string;\n mySecond: number;\n\n myMethod(): void;\n myMethodWithTypeParameter<T... | typescript | edit | 0 | 1 | mit | 438a578cfb20b3debdeec7ca762731db8b60033a | dsherret/ts-type-info,dsherret/type-info-ts,dsherret/ts-type-info,dsherret/type-info-ts | src/tests/definitions/interface/interfaceWriteTests.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/*\n * Copyright 2020 Simon Edwards <<EMAIL>>\n *\n * This source code is licensed under the MIT license which is detailed in the LICENSE.txt file.\n */\nimport Component from 'vue-class-component';\nimport Vue from 'vue';\n\nimport { }... | typescript | edit | 0 | 2 | mit | 7dd4f72ed23bf2d0806f192614225e8b09a473e4 | sedwards2009/extraterm,sedwards2009/extraterm,sedwards2009/extraterm,sedwards2009/extraterm,sedwards2009/extraterm | extraterm/src/render_process/settings/extensions/ExtensionSettingsUi.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport React from 'react';\nimport { Icon, Tooltip } from 'react-components';\nimport { c } from 'ttag';\n\nimport { MessageExtended } from '../../../models/message';\n\ninterface Props {\n message: MessageExtended;\n}\n\nconst Extra... | typescript | edit | null | null | mit | f7fb5e59325f7f4fb670d92d5fe68be38255ccd6 | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | applications/mail/src/app/components/message/extras/ExtraDecryptedSubject.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/* tslint:disable:no-unused-variable */\n\n/*!\n * Suitability Map Panel Component Test\n *\n * Copyright(c) Exequiel Ceasar Navarrete <<EMAIL>>\n * Licensed under MIT\n */\n\nimport { Renderer } from '@angular/core';\nimport { TestBed,... | typescript | edit | 0 | 1 | mit | 5f4c1e977c92268f9e3a01e2560f06e6f29e9024 | ecsnavarretemit/sarai-ng2,ecsnavarretemit/sarai-interactive-maps,ecsnavarretemit/sarai-ng2,ecsnavarretemit/sarai-interactive-maps,ecsnavarretemit/sarai-ng2,ecsnavarretemit/sarai-interactive-maps | src/app/map/suitability-map-panel/suitability-map-panel.component.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport Chart from './Chart';\nimport SvgStrategyParallelCoordinates from '../svg/strategies/SvgStrategyParallelCoordinates';\nimport { defaults } from '../utils/defaults/parallelCoordinates';\nimport { copy, isValuesInObjectKeys } from ... | typescript | edit | 0 | 4 | apache-2.0 | 3113a24cf7e9ff34a03977b90cadcd544369ff0a | proteus-h2020/proteic,proteus-h2020/proteic,proteus-h2020/proteus-charts,proteus-h2020/proteic | src/charts/ParallelCoordinates.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n\"use strict\";\r\n\r\nimport { IRequestParser } from '../models/IRequestParser';\r\nimport { CurlRequestParser } from '../utils/curlRequestParser';\r\nimport { HttpRequestParser } from '../utils/httpRequestParser';\r\n\r\nexport interf... | typescript | edit | 0 | 2 | mit | aff211820893c81d0768931ea2b9d9592919dc85 | Huachao/vscode-restclient,Huachao/vscode-restclient | src/models/requestParserFactory.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { fileSize } from \"../format/filesize\";\n\nimport platformData from \"../constants/platform-data\";\nimport { DateTimeField, toDateTimeField } from \"../db/datetime-field\";\n\nimport { IUpload, ILocalizedString, IModalButtonTa... | typescript | edit | 0 | 7 | mit | 9baa8767b7f2069131b577eca2a0eedb61adf58a | itchio/itchio-app,itchio/itch,itchio/itch,itchio/itch,leafo/itchio-app,leafo/itchio-app,itchio/itchio-app,itchio/itch,leafo/itchio-app,itchio/itch,itchio/itch,itchio/itchio-app | src/reactors/make-upload-button.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport * as React from \"react\";\nimport {Class, Course} from \"../class\"\nimport {Toggle} from \"./utilities/toggle\"\nimport {ClassList} from \"./class-list\"\nimport {Department} from \"./department\"\nexport interface CourseSummar... | typescript | edit | null | null | mit | 6de608a3595470c673067774506de73d6f2a0111 | goodbye-island/S-Store-Front-End,goodbye-island/S-Store-Front-End,goodbye-island/S-Store-Front-End | src/components/course-summary.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { DataCube } from 'src/models/data-cube/data-cube.model';\r\n\r\nexport interface Dataset {\r\n metas: Array<Meta>;\r\n dataCube: DataCube;\r\n}\r\n\r\nexport type Meta = TabbedChartsMeta | ChartMeta;\r\n\r\nexport interface C... | typescript | edit | 0 | 0 | apache-2.0 | f66f5fcc6d74ebc2b4100afe35f69cac04f19376 | googleinterns/guide-doge,googleinterns/guide-doge,googleinterns/guide-doge | src/datasets/types.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport * as glob from \"glob\";\nimport * as Mocha from \"mocha\";\nimport * as path from \"path\";\n\nexport function run(): Promise<void> {\n // Create ... | typescript | edit | 0 | 3 | mit | 6d222f60cb1be7133bef19386a85e5a31c498be8 | PowerShell/vscode-powershell | test/testRunner.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n\n// Copyright 2018 The Outline 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 at\n//\n// ... | typescript | edit | 0 | 0 | apache-2.0 | a4adde6f536b8498e1495768ee3c51c97cef649a | Jigsaw-Code/outline-server,Jigsaw-Code/outline-server,Jigsaw-Code/outline-server,Jigsaw-Code/outline-server | src/shadowbox/model/access_key.ts | rejected_duplicate | Near-duplicate of sample 112623 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { Client } from '../client/Client';\n\n/**\n * Method to be implemented that will be executed whenever the event this handler\n * is for is emitted by the Client\n * @abstact\n * @method Event#action\n * @param {any[]} args - The... | typescript | edit | 0 | 1 | mit | 8207d65c2228ecd75142f1e160c7028959069db9 | zajrik/yamdbf,zajrik/yamdbf | src/event/Event.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport epcis = require('./epcisevents');\n\nexport module EPCIS {\n\texport class EpcisJsonParser {\n\t\tconstructor() {}\n\t\tstatic parseObj(obj: Object) : epcis.EPCIS.EpcisEvent {\n\t\t\tif(EpcisJsonParser.isEvent(obj)) {\n\t\t\t\tif... | typescript | edit | 0 | 4 | mit | a23747f415b9d926025d4789d09bd6a0c5b8a2e7 | matgnt/epcis-js,matgnt/epcis-js | lib/jsonparser.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { Controllers, Controller, HttpController } from './decorators/Controller';\nimport { IHttpMethod, HttpMethods, HttpGet, HttpPost, HttpPut, HttpDelete } from './decorators/HttpMethod';\n\nimport * as express from 'express';\n\nex... | typescript | edit | 0 | 6 | mit | f69ce2593842b7f9d5e99f78d3b575e3982b3094 | mborders/restorator | src/HttpContainer.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { Client, Config, DeepPartial } from 'jovo-client-web';\nimport { PluginObject } from 'vue';\n\ndeclare module 'vue/types/vue' {\n interface Vue {\n $client: Client;\n }\n}\n\nexport interface JovoWebClientVueConfig {\n url... | typescript | edit | 0 | 2 | apache-2.0 | 5a28fe0242ed53c7df77b53302dcfe43c84dca9f | jovotech/jovo-framework-nodejs,jovotech/jovo-framework-nodejs | jovo-clients/jovo-client-web-vue/src/index.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { Store } from 'redux';\nimport { JsonSchema } from './models/jsonSchema';\nimport { UISchemaElement } from './models/uischema';\n\nexport interface JsonFormsStore extends Store<any> {\n}\nexport interface JsonFormsState {\n jso... | typescript | edit | 0 | 0 | mit | 9c3e2db094d06ddc4a7dc3c8a9de899140e4ff7d | qb-project/jsonforms,qb-project/jsonforms,qb-project/jsonforms | packages/core/src/store.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { Grid, Row, Column, Diagonal } from '../definitions';\n\nexport function getRows(grid: Grid): Row[] {\n const length = Math.sqrt(grid.length);\n const copy = grid.concat([]);\n return getArray(length).map(() => copy.splice(0,... | typescript | edit | 0 | 1 | mit | 8c8057b657d725417748b4a89174006ea3acbc15 | artfuldev/tictactoe-ai,artfuldev/tictactoe-ai | src/utils/index.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport {\n beforeEachProviders,\n describe,\n inject,\n it\n} from '@angular/core/testing';\n\nimport { AddAssignmentComponent } from './add-assignment.component';\n\ndescribe('AddAssignmentComponent', () => {\n beforeEachProviders... | typescript | edit | 0 | 1 | mit | 12f638a0eb1fcdf6276488248b3d4678da283138 | bryant-pham/brograder,bryant-pham/brograder,bryant-pham/brograder,bryant-pham/brograder | src/app/add-assignment/add-assignment.component.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n// Type definitions for react-hyperscript 3.0\n// Project: https://github.com/mlmorg/react-hyperscript\n// Definitions by: tock203 <https://github.com/tock203>\n// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped\n// Type... | typescript | edit | 0 | 0 | mit | d47c9aff6ad222e4a2bffda15828c5f5c043b63d | borisyankov/DefinitelyTyped,arusakov/DefinitelyTyped,magny/DefinitelyTyped,AgentME/DefinitelyTyped,AgentME/DefinitelyTyped,zuzusik/DefinitelyTyped,one-pieces/DefinitelyTyped,georgemarshall/DefinitelyTyped,markogresak/DefinitelyTyped,alexdresko/DefinitelyTyped,AgentME/DefinitelyTyped,borisyankov/DefinitelyTyped,arusakov... | types/react-hyperscript/index.d.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport {Id} from '../types'\nimport {isObjectId} from '../helpers'\nimport Post, {DbPost, UpsertPost} from '../models/Post'\n\nexport const findPostById = async (id: Id): Promise<DbPost> => {\n return isObjectId(id) ? await Post.findBy... | typescript | edit | 0 | 2 | mit | d2f1e052f6379d799b57831e8a0847d181153188 | ericnishio/express-boilerplate,ericnishio/express-boilerplate,ericnishio/express-boilerplate | src/db/repositories/postRepository.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/// <reference path=\"../../common/models.ts\" />\n/// <reference path=\"../../../typings/tsd.d.ts\" />\n\nimport StyleHelpers = require(\"./helpers\");\nimport Models = require(\"../../common/models\");\nimport _ = require(\"lodash\");... | typescript | edit | 0 | 2 | isc | a30e9355cf98a8d8f6590187de6b58d7f4f9fd3a | michaelgrosner/tribeca,michaelgrosner/tribeca,michaelgrosner/tribeca | src/service/quoting-styles/style-registry.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { NgModule } from '@angular/core';\nimport { RouterModule, Routes } from '@angular/router';\n\nimport { BuildsPage } from '@page/builds/builds.page';\nimport { ChampionPage } from '@page/champion/champion.page';\nimport { Champio... | typescript | edit | 0 | 0 | mit | 4a52da43a151e26a05946b5d60eb07841fc4160b | drumonii/LeagueTrollBuild,drumonii/LeagueTrollBuild,drumonii/LeagueTrollBuild,drumonii/LeagueTrollBuild | frontend/src/app/app-routing.module.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport {Injectable, Inject} from '@angular/core';\n\n@Injectable()\nexport class UrlUtils {\n\n constructor(@Inject('DataPathUtils') private dataPathUtils) {\n }\n\n public urlIsClearOfParams(url) {\n if (url.indexOf(':'... | typescript | edit | 0 | 0 | mit | a441297e6f5c4492318a6d60bbc292ca4da64b50 | dsternlicht/RESTool,dsternlicht/RESTool,dsternlicht/RESTool | src/app/utils/url.utils.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/** @module react-elementary/lib/mergeProps */\n\nimport classNames = require('classnames')\nimport { mergeWithKey } from 'ramda'\n\nexport interface IReducers { [key: string]: (...args: any[]) => any }\n\nfunction customizeMerges(reduc... | typescript | edit | 0 | 1 | mit | 4b34ca5b7fd4c88b464d6cec22ed4896e44f6329 | thirdhand/react-elementary,thirdhand/react-elementary | src/mergeProps.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { visit } from '../helper';\n\ndescribe('Navigation', () => {\n before(() => {\n visit('official-storybook');\n });\n\n it('should search navigation item', () => {\n cy.get('#storybook-explorer-searchfield').click().clea... | typescript | edit | 0 | 1 | mit | 8d0651a0943990c994dc41ce23a8ae8857d09778 | storybooks/react-storybook,storybooks/react-storybook,storybooks/react-storybook,storybooks/storybook,storybooks/storybook,storybooks/react-storybook,storybooks/storybook,storybooks/storybook,storybooks/storybook,storybooks/storybook,kadirahq/react-storybook,kadirahq/react-storybook,storybooks/storybook | cypress/integration/navigation.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport {App, Platform} from 'ionic-angular';\nimport {TabsPage} from './pages/tabs/tabs';\n\n// https://angular.io/docs/ts/latest/api/core/Type-interface.html\nimport {Type} from 'angular2/core';\n\n\n@App({\n template: '<ion-nav [root... | typescript | edit | 0 | 1 | mit | 7212ad8f8b4d5eb7cb2916cef5f898c1c7d8797b | neilgoldman305/marvin-ui,neilgoldman305/marvin-ui,neilgoldman305/marvin-ui | app/app.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n'use strict';\n\nimport * as cp from 'child_process';\nimport ChildProcess = cp.ChildProcess;\n\nimport { join } from 'path';\n\nconst isWindows = process.platform === 'win32';\nconst isMacintosh = process.platform === 'darwin';\nconst ... | typescript | edit | 0 | 8 | apache-2.0 | 9d269849987fbe374b0f76a4893fdf9d867b8b84 | rust-analyzer/rust-analyzer,rust-analyzer/rust-analyzer,rust-analyzer/rust-analyzer,rust-analyzer/rust-analyzer,rust-analyzer/rust-analyzer | editors/code/src/utils/processes.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { Injectable } from '@angular/core';\nimport { PrometheusApiService } from '../prometheus-api/prometheus-api.service';\nimport { MongooseChartDao } from '../../models/chart/mongoose-chart-interface/mongoose-chart-dao.model';\n\n@... | typescript | edit | 0 | 1 | mit | 3e812032da7246f4056190dbef88fb0c85e0be7f | emc-mongoose/console,emc-mongoose/console,emc-mongoose/console | console/src/app/core/services/charts-provider-service/charts-provider.service.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport React from 'react'\n\nexport default props => {\n const { onClick, disabled } = props\n return (\n <button\n {...{\n onClick,\n disabled\n }}\n className='inline-flex items-center justify-center ... | typescript | edit | null | null | mit | 466700e0829df64dbb854874336311e3552fc355 | xcv58/Tab-Manager-v2,xcv58/Tab-Manager-v2,xcv58/Tab-Manager-v2,xcv58/Tab-Manager-v2 | src/js/components/CloseButton.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { Component, Input, TemplateRef, ViewChild } from '@angular/core';\n\n@Component({\n selector: 'sprk-list-item',\n template: `\n <ng-template>\n <ng-content></ng-content>\n </ng-template>\n `\n})\nexport class SprkL... | typescript | edit | 0 | 0 | mit | 550b7714b4f680eab52c006d19164b5676925b94 | sparkdesignsystem/spark-design-system,sparkdesignsystem/spark-design-system,sparkdesignsystem/spark-design-system,sparkdesignsystem/spark-design-system | src/angular/projects/spark-angular/src/lib/components/sprk-list-item/sprk-list-item.component.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport * as fs from \"fs\";\n\n/**\n * Typing for the fields of package.json we care about\n */\nexport interface PackageJson {\n readonly main: string;\n}\n\nexport interface ReadPackageJson {\n (file: string): PackageJson | undefine... | typescript | edit | 0 | 1 | mit | 5e6e9212aac981e9fe7801d293c125cf9371d509 | dividab/tsconfig-paths,jonaskello/tsconfig-paths,dividab/tsconfig-paths,jonaskello/tsconfig-paths | src/package-reader.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport net = require(\"net\");\n\n/**\n * Represents a given host and port. Handles checking whether a host \n * is up or not, as well as if it is accessible on the given port.\n */\nclass MonitoredSocket {\n /**\n * Returns whe... | typescript | edit | 0 | 1 | mit | c5d9862102c5ba69c4a27a6e89a42a15bab28362 | OzuYatamutsu/is-my-server-up,OzuYatamutsu/is-my-server-up,OzuYatamutsu/is-my-server-up | MonitoredSocket.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/*\n * Copyright 2019 ThoughtWorks, Inc.\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 at\n *\n * ... | typescript | edit | 0 | 5 | apache-2.0 | e5357a99643c7600aa89a5d912fabfb7c7876ad6 | bdpiparva/gocd,bdpiparva/gocd,bdpiparva/gocd,bdpiparva/gocd,bdpiparva/gocd,bdpiparva/gocd | server/src/main/webapp/WEB-INF/rails/webpack/config/loaders/static-assets-loader.ts | rejected_duplicate | Near-duplicate of sample 116409 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport parallel from \"../../src/browser/index\";\n\ndescribe(\"ParallelIntegration\", function () {\n it(\"reduce waits for the result to be computed on the workers and returns the reduced value\", function (done) {\n paral... | typescript | edit | 0 | 1 | mit | 53dad32841ddb39721dd6a3c44de083d507a6ee6 | MichaReiser/parallel.es,MichaReiser/parallel.es,DatenMetzgerX/parallel.es,MichaReiser/parallel.es,DatenMetzgerX/parallel.es,DatenMetzgerX/parallel.es | test/browser/parallel.integration.specs.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport * as React from \"react\";\nimport * as ReactDOM from \"react-dom\";\nimport * as injectTapEventPlugin from \"react-tap-event-plugin\";\nimport MenuBar from \"./components/menu/MenuBar\";\nimport SimpleContent from \"./components... | typescript | edit | null | null | mit | c61266439468e140de5fb50d2c211c8ca4ae4263 | SIT-DigiCre/ShibaurasaiApp,SIT-DigiCre/ShibaurasaiApp,SIT-DigiCre/ShibaurasaiApp | src/main.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Write typescript code for the following: universal: Add SVG loader to exports."
},
{
"role": "assistant",
"content": "export * from './src/angular-svg-icon.module';\nexport * from './src/svg-icon-registry.service';\nexport * from './src/svg-icon.component';\nexport ... | typescript | new_file | 0 | 0 | mit | 7e9b7d0d72ad92f54951d264a7bd282bd07ddff2 | czeckd/angular-svg-icon,czeckd/angular2-svg-icon,czeckd/angular2-svg-icon,czeckd/angular-svg-icon,czeckd/angular2-svg-icon,czeckd/angular-svg-icon | lib/index.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { TestBed, inject } from '@angular/core/testing';\n\nimport { AnnotationExporterService } from './annotation-exporter.service';\n\ndescribe('AnnotationExporterService', () => {\n beforeEach(() => {\n TestBed.configureTestingM... | typescript | edit | 0 | 2 | bsd-3-clause | 3cc5f55cdc15d7e0d043161b7e4b68e76bd90644 | Alveo/alveo-transcriber,Alveo/alveo-transcriber,Alveo/alveo-transcriber,Alveo/alveo-transcriber | projects/alveo-transcriber/src/lib/shared/annotation-exporter.service.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { encodePathAsUrl } from '../../src/lib/path'\n\ndescribe('path', () => {\n describe('encodePathAsUrl', () => {\n if (__WIN32__) {\n it('normalizes path separators on Windows', () => {\n const dirName =\n ... | typescript | edit | 0 | 4 | mit | 033cb0ce0b459fda8db02e77cdf17f9f4e91d5bd | say25/desktop,shiftkey/desktop,desktop/desktop,kactus-io/kactus,artivilla/desktop,desktop/desktop,shiftkey/desktop,artivilla/desktop,desktop/desktop,say25/desktop,shiftkey/desktop,desktop/desktop,j-f1/forked-desktop,shiftkey/desktop,kactus-io/kactus,j-f1/forked-desktop,j-f1/forked-desktop,say25/desktop,j-f1/forked-desk... | app/test/unit/path-test.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport * as React from \"react\";\nimport { FilterConsumer } from \"../context/filter\";\nimport { Container, HiddenInput, NativeInput } from \"./styled\";\n\nexport interface CheckboxProps {\n name: string;\n all?: boolean;\n Checkb... | typescript | edit | null | null | mit | 0a0dd67bd69c0d8b759e264429412c65773373f0 | sajari/sajari-sdk-react,sajari/sajari-sdk-react | src/components/Checkbox/Checkbox.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport net = require(\"net\");\n\n/**\n * Represents a given host and port. Handles checking whether a host \n * is up or not, as well as if it is accessible on the given port.\n */\nclass MonitoredSocket {\n /**\n * Returns whe... | typescript | edit | 0 | 1 | mit | 841735c97c776f8d222e1c5ea885ccc4e5b38a60 | OzuYatamutsu/is-my-server-up,OzuYatamutsu/is-my-server-up,OzuYatamutsu/is-my-server-up | MonitoredSocket.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/// <reference path=\"./redux-logger.d.ts\" />\n\nimport createLogger from 'redux-logger';\nimport { applyMiddleware, createStore } from 'redux'\n\nlet logger = createLogger();\n\nlet loggerWithOpts = createLogger({\n actionTransformer... | typescript | edit | 0 | 1 | mit | d6094b87df963609ce46a6dd0cee2999654072d6 | jraymakers/DefinitelyTyped,florentpoujol/DefinitelyTyped,gandjustas/DefinitelyTyped,johan-gorter/DefinitelyTyped,smrq/DefinitelyTyped,zuzusik/DefinitelyTyped,georgemarshall/DefinitelyTyped,subash-a/DefinitelyTyped,martinduparc/DefinitelyTyped,AgentME/DefinitelyTyped,eugenpodaru/DefinitelyTyped,mcrawshaw/DefinitelyTyped... | redux-logger/redux-logger-tests.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport React from 'react'\nimport { Link } from 'react-router-dom'\nimport styled from 'styled-components'\n\nimport { mixin as boxMixin } from 'v2/components/UI/Box'\nimport Text from 'v2/components/UI/Text'\n\nconst Container = styled... | typescript | edit | null | null | mit | c710fc7eb3e5d3d405b8c6f1be29ab01a22fa312 | aredotna/ervell,aredotna/ervell,aredotna/ervell,aredotna/ervell,aredotna/ervell | src/v2/components/TopBar/components/AdvancedPrimarySearch/components/AdvancedSearchReturnLabel/index.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n//\n// PLEASE DO NOT MODIFY / DELETE UNLESS YOU KNOW WHAT YOU ARE DOING\n//\n// This file is providing the test runner to use when running extension tests.\n// By default the test runner in use is Mocha based.\n//\n// You can provide yo... | typescript | edit | 0 | 0 | mit | ac630ff69b2c5b83771f881beda99538519c407b | manuth/MarkdownConverter,manuth/MarkdownConverter,manuth/MarkdownConverter | src/test/index.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nconst mockGet = jest.fn(() => {\n return Promise.resolve({ data: [mockLog.body] });\n});\njest.mock(\"axios\", () => ({ default: { get: mockGet } }));\nimport { refreshLogs } from \"../refresh_logs\";\nimport axios from \"axios\";\nimp... | typescript | edit | 0 | 1 | mit | 685074456648ecea6c0f9f3a92948fc006e18f63 | FarmBot/farmbot-web-app,RickCarlino/farmbot-web-app,RickCarlino/farmbot-web-app,FarmBot/farmbot-web-app,gabrielburnworth/Farmbot-Web-App,gabrielburnworth/Farmbot-Web-App,gabrielburnworth/Farmbot-Web-App,FarmBot/Farmbot-Web-API,FarmBot/farmbot-web-app,gabrielburnworth/Farmbot-Web-App,FarmBot/Farmbot-Web-API,FarmBot/Farm... | webpack/redux/__tests__/refresh_logs_tests.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n/// <reference path=\"../../../typings/globals/jasmine/index.d.ts\" />\n\nimport {\n Component,\n ViewChildren,\n QueryList\n} from '@angular/core';\n\nimport {\n TestBed\n} from '@angular/core/testing';\n\nimport {\n DxD... | typescript | edit | 0 | 1 | mit | f53d0036edff12d57f355a051b524b6c3ebc5021 | DevExpress/devextreme-angular,DevExpress/devextreme-angular,DevExpress/devextreme-angular | tests/src/ui/data-grid.spec.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { useCallback } from 'react';\nimport { useSelection } from '../state/useSelection';\n\nexport const useFileBrowserCheckbox = (id: string) => {\n const selectionControls = useSelection();\n const isSelected = Boolean(select... | typescript | edit | 0 | 5 | mit | 3b4477bf919002351585f343e5e07c7ddcce9c79 | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | applications/drive/src/app/components/FileBrowser/hooks/useFileBrowserCheckbox.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { Client, TextChannel, Message } from 'discord.js';\nimport { getCharacters } from './characters';\nimport QuoteManager from './quoteManager';\nconst client = new Client();\n\nlet quoteManager: QuoteManager;\n\nclient.on('ready',... | typescript | edit | 0 | 6 | mit | 327924ca0cbfede69d31e247149c53510ed28c6e | Lockeid/CuillerBot | src/index.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { Application } from 'express';\nimport * as request from 'supertest';\n\nimport { createServer } from '../src/server';\n\ndescribe('routes', () => {\n let app: Application;\n\n before('create app', async () => {\n a... | typescript | edit | 0 | 2 | mit | 0acb6649bb9d7f18f55c6a0061e813abc0adc79d | mattbdean/Helium,mattbdean/Helium,mattbdean/Helium,mattbdean/Helium | server/test/routes.test.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport {Doc, RemoteMutationWithVersion, TransactionLogEvent} from './types'\n\nexport type TraceEvent =\n | {\n type: 'initial'\n publishedId: string\n draft: Doc | null\n published: Doc | null\n }\n | {type: 'a... | typescript | edit | 0 | 8 | mit | 7fbeaf1ad4bf164e1018acfa4e1759026c700116 | sanity-io/sanity,sanity-io/sanity,sanity-io/sanity,sanity-io/sanity | packages/@sanity/desk-tool/src/panes/documentPane/documentHistory/history/tracer.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport reducer, {defaultState} from 'src/logs/reducers'\nimport {setTimeWindow} from 'src/logs/actions'\n\ndescribe('Logs.Reducers', () => {\n it('can set a time window', () => {\n const expected = {\n timeOption: 'now',\n ... | typescript | edit | 0 | 1 | mit | ca2e198e90a2b722f86d2344471fa41476e8f7c9 | mark-rushakoff/influxdb,mark-rushakoff/influxdb,mark-rushakoff/influxdb,influxdb/influxdb,mark-rushakoff/influxdb,nooproblem/influxdb,influxdb/influxdb,influxdb/influxdb,nooproblem/influxdb,li-ang/influxdb,influxdata/influxdb,li-ang/influxdb,nooproblem/influxdb,mark-rushakoff/influxdb,influxdata/influxdb,nooproblem/inf... | ui/test/logs/reducers/logs.test.ts | rejected_duplicate | Near-duplicate of sample 115742 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { fromObservable, Model, notify } from '../src/lib/model';\nimport { Updatable } from '../src/lib/updatable';\nimport { Observable } from 'rxjs/Observable';\nimport { Subject } from 'rxjs/Subject';\n\nlet chai = require(\"chai\")... | typescript | edit | 0 | 2 | bsd-3-clause | 6691c2c6baa498cfa7ab685ac06fbee97dd39e89 | paulcbetts/trickline,paulcbetts/trickline,paulcbetts/trickline,paulcbetts/trickline | test/support.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nexport class HttpUtils {\n\n // NOTE: Checks if string matches an IP by pattern.\n public static isIpAddressValid(ipAddress: string): boolean {\n let ipValidationRegex: RegExp = new RegExp(/^(25[0-5]|2[0-4][0-9]|[01]?[0-9][... | typescript | edit | 0 | 4 | mit | 4cf61e4273534a9f3254e3121e75f8be4cf3de5d | emc-mongoose/console,emc-mongoose/console,emc-mongoose/console | console/src/app/common/HttpUtils.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { Aurelia, PLATFORM } from 'aurelia-framework';\nimport { Router, RouterConfiguration } from 'aurelia-router';\n\nexport class App {\n router: Router;\n\n configureRouter(config: RouterConfiguration, router: Router) {\n ... | typescript | edit | 0 | 1 | apache-2.0 | 57aae1f7556284176ffe0dd1c0e7cbdfbd212f3e | aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore | src/Microsoft.AspNetCore.SpaTemplates/content/Aurelia-CSharp/ClientApp/app/components/app/app.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n// Copyright 2016 Joe Duffy. All rights reserved.\n\n\"use strict\";\n\nexport function extend<T, U>(t: T, u: U): T & U;\nexport function extend<T, U, V>(t: T, u: U, v: V): T & U & V;\nexport function extend<T, U, V, W>(t: T, u: U, v: V... | typescript | edit | 0 | 1 | mit | 9bf3ae8f7ff7a2dd17673bc0855426fecb57b407 | joeduffy/nodets | src/object/index.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport React from 'react';\nimport { c } from 'ttag';\nimport { APPS, SSO_PATHS } from 'proton-shared/lib/constants';\n\nimport TopBanner from './TopBanner';\nimport { useConfig } from '../../hooks';\nimport { Href } from '../../compone... | typescript | edit | null | null | mit | 901618a3fc1563662277d40d00202bd906d69852 | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | packages/components/containers/topBanners/WelcomeV4TopBanner.tsx | rejected_syntax | Syntax error detected by tree-sitter | false |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\n// Type definitions for js-md5 v0.4.2\n// Project: https://github.com/emn178/js-md5\n// Definitions by: Michael McCarthy <https://github.com/mwmccarthy>\n// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped/\n\ndeclare nam... | typescript | edit | 0 | 0 | mit | cf15d34bc47ea7a7b4e553ebb749e76e91bf36b7 | AgentME/DefinitelyTyped,aciccarello/DefinitelyTyped,borisyankov/DefinitelyTyped,benishouga/DefinitelyTyped,amir-arad/DefinitelyTyped,AgentME/DefinitelyTyped,smrq/DefinitelyTyped,jimthedev/DefinitelyTyped,markogresak/DefinitelyTyped,QuatroCode/DefinitelyTyped,YousefED/DefinitelyTyped,AbraaoAlves/DefinitelyTyped,aciccare... | js-md5/index.d.ts | rejected_duplicate | Near-duplicate of sample 113084 | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport PheromoneNetwork from './PheromoneNetwork'\n\n// --- Properties ---\n\nObject.defineProperty(Room.prototype, 'pheromoneNetwork', {\n configurable: true,\n get(this: Room) {\n if (this._pheromoneNetwork === undefined && this.... | typescript | edit | 0 | 2 | unlicense | cd81e24cea5ded7f178174a1f40631e566ebef5e | tinnvec/aints,tinnvec/aints | src/components/Room.ts | accepted | null | true |
[
{
"role": "user",
"content": "Here is the current file:\n```typescript\nimport { registerExamples } from './register';\nimport { data as personData, } from './person';\n\nexport const schema = undefined;\nexport const uischema = undefined;\nexport const data = personData;\n\nregisterExamples([\n {\n na... | typescript | edit | 0 | 0 | mit | 65c79a775feb264d08ca6fce6fbba5ae1822cf63 | qb-project/jsonforms,qb-project/jsonforms,qb-project/jsonforms | packages/examples/src/generateUI.ts | accepted | null | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.