UNPKG

@arcgis/coding-components

Version:

Contains components for editing code in different languages. The currently supported languages are html, css, json, TypeScript, JavaScript, and Arcade.

32 lines (31 loc) 974 B
import { IArcadeWorker } from './types'; import { Uri } from 'monaco-editor'; import type * as arcadeModeModule from "./arcade-mode"; type ArcadeModeType = typeof arcadeModeModule; /** * Returns the arcade diagnostic service. * Example: * ```ts * const diagnosticService = await getArcadeDiagnosticService(); * diagnosticService.onDidChangeDiagnostics(({uri, diaganostics }) => { * // Filter the diagnostics for the uri of interest * // Do something with the diagnostics * }); * ``` */ export declare function getArcadeDiagnosticService(): Promise<arcadeModeModule.IDiagnosticService>; /** * Returns the arcade worker for the model. * Example: * ```ts * const arcadeWorker = await getArcadeWorker(model.uri); * ``` * @returns arcade worker */ export declare function getArcadeWorker(uri: Uri): Promise<IArcadeWorker>; /** * Request the arcade mode * @returns arcade mode module */ export declare function getMode(): Promise<ArcadeModeType>; export {};