type stringclasses 7
values | content stringlengths 4 9.55k | repo stringlengths 7 96 | path stringlengths 4 178 | language stringclasses 1
value |
|---|---|---|---|---|
MethodDeclaration |
loadAd(params: NativeAdLoadOptions): Promise<void> {
return this.call('loadAd', params)
} | krtek1979/cordova-plugin-hms-ads | scripts/native.ts | TypeScript |
MethodDeclaration |
isLoaded(): Promise<IsLoadedResult> {
return this.call('isLoaded')
} | krtek1979/cordova-plugin-hms-ads | scripts/native.ts | TypeScript |
MethodDeclaration |
isLoading(): Promise<IsLoadingResult> {
return this.call('isLoading')
} | krtek1979/cordova-plugin-hms-ads | scripts/native.ts | TypeScript |
MethodDeclaration |
show(): Promise<void> {
return this.call('show', this.refreshProps())
} | krtek1979/cordova-plugin-hms-ads | scripts/native.ts | TypeScript |
MethodDeclaration |
destroy(): Promise<void> {
nativeViews.delete(this.element.id)
return this.call('destroy')
} | krtek1979/cordova-plugin-hms-ads | scripts/native.ts | TypeScript |
MethodDeclaration |
setProps(props?: NativeAdProps): Promise<void> {
return this.call('setProps', props)
} | krtek1979/cordova-plugin-hms-ads | scripts/native.ts | TypeScript |
ArrowFunction |
(obj, ret) => {
delete ret._id, delete ret.__v
} | ngtrdai197/Intro-Nestjs-GraphQL | src/message/schemas/message.schema.ts | TypeScript |
FunctionDeclaration |
export function annotationQueryFields() {
const fields = DEFAULT_ANNOTATION_QUERY_FIELDS;
if (SHOW_MUTATION_ASSESSOR) {
fields.push('mutation_assessor');
}
return fields;
} | genome-nexus/genome-nexus-frontend | src/config/configDefaults.ts | TypeScript |
ArrowFunction |
({ query: _getContentQuery }: Request, res: Response) => {
const getContentQuery: GetContentQuery = plainToClass(GetContentQuery, _getContentQuery);
validate(getContentQuery).then(validationErrors => {
const [ validationError ] = validationErrors;
if (validationE... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
validationErrors => {
const [ validationError ] = validationErrors;
if (validationError) {
const { constraints } = validationError;
res.send(responseService.BadRequest(JSON.stringify(constraints)));
return;
};
... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
result => {
res.send(responseService.Success(result));
} | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
error => {
res.send(responseService.InternalServerError(JSON.stringify(error)));
} | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
error => {
res.send(responseService.InternalServerError(JSON.stringify(error)));
} | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
({ body: _createContentInput }: Request, res: Response) => {
const createContentInput: CreateContentInput = plainToClass(CreateContentInput, _createContentInput);
validate(createContentInput).then(validationErrors => {
const [ validationError ] = validationErrors;
... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
validationErrors => {
const [ validationError ] = validationErrors;
if (validationError) {
const { constraints } = validationError;
res.send(responseService.BadRequest(JSON.stringify(constraints)));
return;
};
... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
result => {
const { seq, seqBase } = getNextSequence(result);
createContentInput.seq = seq;
createContentInput.seqBase = seqBase;
return contentRepository.save(createContentInput);
} | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
result => {
const { id } = result;
res.send(responseService.Success(id));
} | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
({ body: updateContentInput, params: { id } }: Request, res: Response) => {
contentRepository.update({ id }, updateContentInput).then(_ => {
res.send(responseService.Success(true));
}).catch(error => {
res.send(responseService.InternalServerError(JSON.stringify(e... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
_ => {
res.send(responseService.Success(true));
} | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
({ params: { id } }: Request, res: Response) => {
contentRepository.delete({ id }).then(_ => {
res.send(responseService.Success(true));
}).catch(error => {
res.send(responseService.InternalServerError(JSON.stringify(error)));
});
} | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
({ params: { id } }: Request, res: Response) => {
let target;
contentRepository.findOne(id).then(result => {
const { page } = result;
target = result;
return contentRepository.find({ where: { page } });
}).then(result => {
... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
result => {
const { page } = result;
target = result;
return contentRepository.find({ where: { page } });
} | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
result => {
const nextSequence = getUpSequence(result, target);
return contentRepository.update({ id }, nextSequence);
} | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
({ params: { id } }: Request, res: Response) => {
let target;
contentRepository.findOne(id).then(result => {
const { page } = result;
target = result;
return contentRepository.find({ where: { page } });
}).then(result => {
... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ArrowFunction |
result => {
const nextSequence = getDownSequence(result, target);
return contentRepository.update({ id }, nextSequence);
} | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ClassDeclaration |
export class ContentService {
constructor(
private contentRepository: Repository<Content>,
private responseService: ResponseService
) { }
list(): ControllerFn {
const responseService = this.responseService;
const contentRepository = this.contentRepository;
return (... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
MethodDeclaration |
list(): ControllerFn {
const responseService = this.responseService;
const contentRepository = this.contentRepository;
return ({ query: _getContentQuery }: Request, res: Response) => {
const getContentQuery: GetContentQuery = plainToClass(GetContentQuery, _getContentQuery);
... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
MethodDeclaration |
create(): ControllerFn {
const responseService = this.responseService;
const contentRepository = this.contentRepository;
return ({ body: _createContentInput }: Request, res: Response) => {
const createContentInput: CreateContentInput = plainToClass(CreateContentInput, _createConten... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
MethodDeclaration |
update(): ControllerFn {
const responseService = this.responseService;
const contentRepository = this.contentRepository;
return ({ body: updateContentInput, params: { id } }: Request, res: Response) => {
contentRepository.update({ id }, updateContentInput).then(_ => {
... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
MethodDeclaration |
delete(): ControllerFn {
const responseService = this.responseService;
const contentRepository = this.contentRepository;
return ({ params: { id } }: Request, res: Response) => {
contentRepository.delete({ id }).then(_ => {
res.send(responseService.Success(true));
... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
MethodDeclaration |
upSeq(): ControllerFn {
const responseService = this.responseService;
const contentRepository = this.contentRepository;
return ({ params: { id } }: Request, res: Response) => {
let target;
contentRepository.findOne(id).then(result => {
const { page } = r... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
MethodDeclaration |
downSeq(): ControllerFn {
const responseService = this.responseService;
const contentRepository = this.contentRepository;
return ({ params: { id } }: Request, res: Response) => {
let target;
contentRepository.findOne(id).then(result => {
const { page } =... | cocm1324/mount-api | src/routers/content/content.service.ts | TypeScript |
ClassDeclaration |
@NgModule({
declarations: [
DialogSampleComponent
],
imports: [
IgxComponentsModule,
IgxDirectivesModule,
PageHeaderModule
]
})
export class DialogSampleModule { } | jberes/igniteui-js-blocks | demos/app/dialog/sample.module.ts | TypeScript |
EnumDeclaration |
export enum SortType{
ASC = 'asc',
DESC = 'desc'
} | BrainTrainerProject/cyclejs | src/common/SortType.ts | TypeScript |
ClassDeclaration |
@Component({
moduleId: module.id,
selector: "license-section",
templateUrl: "license-section.component.html",
encapsulation: ViewEncapsulation.None,
changeDetection: ChangeDetectionStrategy.OnPush
})
export class LicenseSectionComponent extends AbstractBaseComponent {
@Input() document: OasDoc... | AlexBe1ov/apicurio-studio | front-end/studio/src/app/pages/apis/{apiId}/editor/_components/forms/main/license-section.component.ts | TypeScript |
MethodDeclaration | /**
* Returns true if a license has been configured for this API.
*/
public hasLicense(): boolean {
if (this.document.info && this.document.info.license) {
return true;
}
return false;
} | AlexBe1ov/apicurio-studio | front-end/studio/src/app/pages/apis/{apiId}/editor/_components/forms/main/license-section.component.ts | TypeScript |
MethodDeclaration | /**
* Returns the resolved license or null if not found.
*/
public license(): ILicense {
return this.licenseService.findLicense(this.licenseUrl());
} | AlexBe1ov/apicurio-studio | front-end/studio/src/app/pages/apis/{apiId}/editor/_components/forms/main/license-section.component.ts | TypeScript |
MethodDeclaration | /**
* Returns the license model.
*/
public licenseModel(): OasLicense {
if (this.document.info && this.document.info.license) {
return this.document.info.license;
} else {
return null;
}
} | AlexBe1ov/apicurio-studio | front-end/studio/src/app/pages/apis/{apiId}/editor/_components/forms/main/license-section.component.ts | TypeScript |
MethodDeclaration | /**
* returns the license name.
*/
public licenseName(): string {
if (this.document.info && this.document.info.license) {
return this.document.info.license.name;
} else {
return "";
}
} | AlexBe1ov/apicurio-studio | front-end/studio/src/app/pages/apis/{apiId}/editor/_components/forms/main/license-section.component.ts | TypeScript |
MethodDeclaration | /**
* returns the license url.
*/
public licenseUrl(): string {
if (this.document.info && this.document.info.license) {
return this.document.info.license.url;
} else {
return "";
}
} | AlexBe1ov/apicurio-studio | front-end/studio/src/app/pages/apis/{apiId}/editor/_components/forms/main/license-section.component.ts | TypeScript |
MethodDeclaration | /**
* Called when the user chooses a new license in the Choose License dialog.
* @param licenseInfo
*/
public setLicense(licenseInfo: any): void {
let command: ICommand = CommandFactory.createChangeLicenseCommand(licenseInfo.name, licenseInfo.url);
this.commandService.emit(command);
... | AlexBe1ov/apicurio-studio | front-end/studio/src/app/pages/apis/{apiId}/editor/_components/forms/main/license-section.component.ts | TypeScript |
MethodDeclaration | /**
* Called when the user chooses to remove the license.
*/
public deleteLicense(): void {
let command: ICommand = CommandFactory.createDeleteLicenseCommand(this.document.info);
this.commandService.emit(command);
} | AlexBe1ov/apicurio-studio | front-end/studio/src/app/pages/apis/{apiId}/editor/_components/forms/main/license-section.component.ts | TypeScript |
ArrowFunction |
(doi: string) =>
'https://doi.org/' + encodeURIComponent(doi.replace(/^.*?(10\.)/, '$1')) | hubgit/manuscripts-library | src/lib/variable-wrapper.ts | TypeScript |
ArrowFunction |
(url: string, contents: string): Element => {
const element = document.createElement('a')
element.setAttribute('href', url)
element.innerHTML = contents // IMPORTANT: this is HTML so must be sanitised later
return element
} | hubgit/manuscripts-library | src/lib/variable-wrapper.ts | TypeScript |
ArrowFunction |
(contents: string): Element => {
const element = document.createElement('span')
element.innerHTML = contents // IMPORTANT: this is HTML so must be sanitised later
return element
} | hubgit/manuscripts-library | src/lib/variable-wrapper.ts | TypeScript |
ArrowFunction |
(
field: string,
itemData: CSL.Data,
str: string
): Element => {
switch (field) {
case 'title': {
if (itemData.DOI) {
return createLink(createDoiUrl(itemData.DOI), str)
}
if (itemData.URL) {
return createLink(itemData.URL, str)
}
return createSpan(str)
}
... | hubgit/manuscripts-library | src/lib/variable-wrapper.ts | TypeScript |
ArrowFunction |
(
params,
prePunct,
str,
postPunct
) => {
if (params.context === 'bibliography') {
const fields = params.variableNames.join(' ')
const element = wrapVariable(fields, params.itemData, str)
element.setAttribute('data-field', fields)
return `${prePunct}${element.outerHTML}${postPunct}`
}
... | hubgit/manuscripts-library | src/lib/variable-wrapper.ts | TypeScript |
ArrowFunction |
(standard: systemlokalitet) | cinnamoncoin/riecoin-86 | src/qt/locale/bitcoin_da.ts | TypeScript |
ArrowFunction |
(standard: 8333 eller testnetværk: 18333) | cinnamoncoin/riecoin-86 | src/qt/locale/bitcoin_da.ts | TypeScript |
ArrowFunction |
(standard: 8332 eller testnetværk: 18332) | cinnamoncoin/riecoin-86 | src/qt/locale/bitcoin_da.ts | TypeScript |
ArrowFunction |
(standard: 127.0.0.1) | cinnamoncoin/riecoin-86 | src/qt/locale/bitcoin_da.ts | TypeScript |
ArrowFunction |
(standard: 100) | cinnamoncoin/riecoin-86 | src/qt/locale/bitcoin_da.ts | TypeScript |
ArrowFunction |
(value, key) => {
let uri = URI.parse(key);
callback.apply(thisArg, [uri, this.get(uri), this]);
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
ArrowFunction |
collection => {
collection.forEach((uri, diagnostics) => {
let idx = index.get(uri.toString());
if (typeof idx === 'undefined') {
idx = res.length;
index.set(uri.toString(), idx);
res.push([uri, []]);
}
res[idx][1] = res[idx][1].concat(...diagnostics);
});
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
ArrowFunction |
(uri, diagnostics) => {
let idx = index.get(uri.toString());
if (typeof idx === 'undefined') {
idx = res.length;
index.set(uri.toString(), idx);
res.push([uri, []]);
}
res[idx][1] = res[idx][1].concat(...diagnostics);
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
ArrowFunction |
collection => {
if (collection.has(resource)) {
res = res.concat(collection.get(resource));
}
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
ClassDeclaration |
export class DiagnosticCollection implements vscode.DiagnosticCollection {
private readonly _name: string;
private readonly _owner: string;
private readonly _maxDiagnosticsPerFile: number;
private readonly _onDidChangeDiagnostics: Emitter<(vscode.Uri | string)[]>;
private readonly _proxy: MainThreadDiagnosticsSh... | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
ClassDeclaration |
export class ExtHostDiagnostics implements ExtHostDiagnosticsShape {
private static _idPool: number = 0;
private static readonly _maxDiagnosticsPerFile: number = 1000;
private readonly _proxy: MainThreadDiagnosticsShape;
private readonly _collections = new Map<string, DiagnosticCollection>();
private readonly _... | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
dispose(): void {
if (!this._isDisposed) {
this._onDidChangeDiagnostics.fire(keys(this._data));
this._proxy.$clear(this._owner);
this._data = undefined;
this._isDisposed = true;
}
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
set(uri: vscode.Uri, diagnostics: vscode.Diagnostic[]): void; | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
set(entries: [vscode.Uri, vscode.Diagnostic[]][]): void; | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
set(first: vscode.Uri | [vscode.Uri, vscode.Diagnostic[]][], diagnostics?: vscode.Diagnostic[]) {
if (!first) {
// this set-call is a clear-call
this.clear();
return;
}
// the actual implementation for #set
this._checkDisposed();
let toSync: vscode.Uri[] = [];
let hasChanged = true;
if (firs... | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
delete(uri: vscode.Uri): void {
this._checkDisposed();
this._onDidChangeDiagnostics.fire([uri]);
this._data.delete(uri.toString());
this._proxy.$changeMany(this._owner, [[uri, undefined]]);
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
clear(): void {
this._checkDisposed();
this._onDidChangeDiagnostics.fire(keys(this._data));
this._data.clear();
this._proxy.$clear(this._owner);
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
forEach(callback: (uri: URI, diagnostics: vscode.Diagnostic[], collection: DiagnosticCollection) => any, thisArg?: any): void {
this._checkDisposed();
this._data.forEach((value, key) => {
let uri = URI.parse(key);
callback.apply(thisArg, [uri, this.get(uri), this]);
});
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
get(uri: URI): vscode.Diagnostic[] {
this._checkDisposed();
let result = this._data.get(uri.toString());
if (Array.isArray(result)) {
return <vscode.Diagnostic[]>Object.freeze(result.slice(0));
}
return undefined;
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
has(uri: URI): boolean {
this._checkDisposed();
return Array.isArray(this._data.get(uri.toString()));
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
private _checkDisposed() {
if (this._isDisposed) {
throw new Error('illegal state - object is disposed');
}
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
private static _compareIndexedTuplesByUri(a: [vscode.Uri, vscode.Diagnostic[]], b: [vscode.Uri, vscode.Diagnostic[]]): number {
if (a[0].toString() < b[0].toString()) {
return -1;
} else if (a[0].toString() > b[0].toString()) {
return 1;
} else {
return 0;
}
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
static _debouncer(last: (vscode.Uri | string)[], current: (vscode.Uri | string)[]): (vscode.Uri | string)[] {
if (!last) {
return current;
} else {
return last.concat(current);
}
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
static _mapper(last: (vscode.Uri | string)[]): { uris: vscode.Uri[] } {
let uris: vscode.Uri[] = [];
let map = new Set<string>();
for (const uri of last) {
if (typeof uri === 'string') {
if (!map.has(uri)) {
map.add(uri);
uris.push(URI.parse(uri));
}
} else {
if (!map.has(uri.toString... | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
createDiagnosticCollection(name?: string): vscode.DiagnosticCollection {
let { _collections, _proxy, _onDidChangeDiagnostics } = this;
let owner: string;
if (!name) {
name = '_generated_diagnostic_collection_name_#' + ExtHostDiagnostics._idPool++;
owner = name;
} else if (!_collections.has(name)) {
ow... | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
dispose() {
super.dispose();
_collections.delete(owner);
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
getDiagnostics(resource: vscode.Uri): vscode.Diagnostic[]; | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
getDiagnostics(): [vscode.Uri, vscode.Diagnostic[]][]; | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
getDiagnostics(resource?: vscode.Uri): vscode.Diagnostic[] | [vscode.Uri, vscode.Diagnostic[]][]; | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
getDiagnostics(resource?: vscode.Uri): vscode.Diagnostic[] | [vscode.Uri, vscode.Diagnostic[]][] {
if (resource) {
return this._getDiagnostics(resource);
} else {
let index = new Map<string, number>();
let res: [vscode.Uri, vscode.Diagnostic[]][] = [];
this._collections.forEach(collection => {
coll... | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
MethodDeclaration |
private _getDiagnostics(resource: vscode.Uri): vscode.Diagnostic[] {
let res: vscode.Diagnostic[] = [];
this._collections.forEach(collection => {
if (collection.has(resource)) {
res = res.concat(collection.get(resource));
}
});
return res;
} | Ashniu123/vscode | src/vs/workbench/api/node/extHostDiagnostics.ts | TypeScript |
ArrowFunction |
({
title,
url,
imgSrc,
}: {
imgSrc: string;
title: string;
url: string;
}) => (
<Grid item | dvargas92495/website | pages/projects.tsx | TypeScript |
ArrowFunction |
({
title,
url,
description,
}: {
description: string;
title: string;
url: string;
}) => (
<Grid item | dvargas92495/website | pages/projects.tsx | TypeScript |
ArrowFunction |
({
title,
link,
description,
imgSrc,
ltr,
}: {
title: string;
link: string;
description: string;
imgSrc: string;
ltr: boolean;
}) => {
const [showDescription, setShowDescription] = window.React.useState(false);
const openDescription = window.React.useCallback(
() => setShowDescription(true)... | dvargas92495/website | pages/projects.tsx | TypeScript |
ArrowFunction |
() => setShowDescription(true) | dvargas92495/website | pages/projects.tsx | TypeScript |
ArrowFunction |
() => setShowDescription(false) | dvargas92495/website | pages/projects.tsx | TypeScript |
ArrowFunction |
({ projects }: { projects: Projects }) => (
<Grid container | dvargas92495/website | pages/projects.tsx | TypeScript |
ArrowFunction |
({ name, url, description, image }, i) =>
image && description ? (
<Project
key={i} | dvargas92495/website | pages/projects.tsx | TypeScript |
ArrowFunction |
d => {
(d as HTMLDivElement).style.paddingTop = "0";
window.ReactDOM.render(
<ProjectsPage projects={window[d.id] as Projects} />,
d
);
} | dvargas92495/website | pages/projects.tsx | TypeScript |
InterfaceDeclaration |
interface Window {
[k: string]: Projects;
React: typeof React;
ReactDOM: typeof ReactDOM;
} | dvargas92495/website | pages/projects.tsx | TypeScript |
TypeAliasDeclaration |
type Projects = {
name: string;
url: string;
description?: string;
image?: string;
}[]; | dvargas92495/website | pages/projects.tsx | TypeScript |
MethodDeclaration |
url ? (
<Link href={url} target="_blank" rel="noopener">
{title}
</Link>
) : (
title
) | dvargas92495/website | pages/projects.tsx | TypeScript |
FunctionDeclaration |
async function copyFile(from: string, to = from) {
to = join("npm", to);
await ensureDir(dirname(to));
await Deno.copyFile(from, to);
} | jhogendorn/keep-a-changelog | build_npm.ts | TypeScript |
ClassDeclaration |
@Component({
selector: 'app-page-2',
templateUrl: './parent.component.html',
styleUrls: ['./parent.component.scss']
})
export class Page2ParentComponent implements OnInit {
parentMessage = "Message from the Parent : Do something awesome with Angular. 😎"
parentMessageList = ["Al Kindi", "Friedrich Nietzsche... | SaraO2/CHI-Angular-Tutorials | T003-Routing With 2 Components(routing)/src/app/page-2/parent.component.ts | TypeScript |
MethodDeclaration |
addItem(newItem: string) {
this.items.push(newItem);
} | SaraO2/CHI-Angular-Tutorials | T003-Routing With 2 Components(routing)/src/app/page-2/parent.component.ts | TypeScript |
ArrowFunction |
(callback) => {
this._connectionResolver.resolve(correlationId, (err, connection) => {
this._connection = connection;
if (callback != null)
callback(err);
});
} | iquipsys-positron/iqs-services-cloudwatch-node | src/logic/CloudwatchController.ts | TypeScript |
ArrowFunction |
(err, connection) => {
this._connection = connection;
if (callback != null)
callback(err);
} | iquipsys-positron/iqs-services-cloudwatch-node | src/logic/CloudwatchController.ts | TypeScript |
ArrowFunction |
(callback) => {
let aws = require('aws-sdk');
aws.config.update({
accessKeyId: this._connection.getAccessId(),
secretAccessKey: this._connection.getAccessKey(),
region: this._connection.getRegion()
});
... | iquipsys-positron/iqs-services-cloudwatch-node | src/logic/CloudwatchController.ts | TypeScript |
ArrowFunction |
(err, data) => {
if (err) {
// this._logger.error(correlationId, "Error while describeLogGroups: %s; Stack: %s", err, err.stack);
console.log(err, err.stack);
}
if (callback) callback(err, data);
} | iquipsys-positron/iqs-services-cloudwatch-node | src/logic/CloudwatchController.ts | TypeScript |
ArrowFunction |
(err, data) => {
if (err) {
// this._logger.error(correlationId, "Error while describeLogStreams: %s; Stack: %s", err, err.stack);
console.log(err, err.stack);
}
if (callback) callback(err, data);
} | iquipsys-positron/iqs-services-cloudwatch-node | src/logic/CloudwatchController.ts | TypeScript |
ArrowFunction |
(callback) => {
let listMetricsparams: any;
if (metric) {
listMetricsparams = {
Namespace: namespace,
MetricName: metric
};
} else {
listMetricsparams = {
... | iquipsys-positron/iqs-services-cloudwatch-node | src/logic/CloudwatchController.ts | TypeScript |
ArrowFunction |
(callback) => {
if (metrics.length == 0) {
// this._logger.trace(correlationId, "Not found metrics data for %s namespace", namespace);
console.log("Not found metrics data for %s namespace", namespace);
callback(null, "Not found metrics data fo... | iquipsys-positron/iqs-services-cloudwatch-node | src/logic/CloudwatchController.ts | TypeScript |
ArrowFunction |
metric => {
let dimensions = [];
metric.Dimensions.forEach(dimension => {
dimensions.push({
Name: dimension.Name,
Value: dimension.Value
})
});
... | iquipsys-positron/iqs-services-cloudwatch-node | src/logic/CloudwatchController.ts | TypeScript |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.