Skip to main content
Module

x/capi/deps/dprint.ts>Formatter

[WIP] A framework for crafting interactions with Substrate chains
Latest
interface Formatter
import { type Formatter } from "https://deno.land/x/capi@v0.1.1-beta.1/deps/dprint.ts";

Formats code.

Methods

setConfig(globalConfig: GlobalConfiguration, pluginConfig: Record<string, unknown>): void

Sets the configuration.

getConfigDiagnostics(): ConfigurationDiagnostic[]

Gets the configuration diagnostics.

getResolvedConfig(): Record<string, unknown>

Gets the resolved configuration.

getPluginInfo(): PluginInfo

Gets the plugin info.

getLicenseText(): string

Gets the license text of the plugin.

formatText(
filePath: string,
fileText: string,
overrideConfig?: Record<string, unknown>,
): string

Formats the specified file text.