@@ -34,7 +34,7 @@ export declare const enum Severity {
3434 * # Panics
3535 * Panics if the current working directory cannot be determined.
3636 */
37- export declare function format ( filename : string , sourceText : string , options : any | undefined | null , initExternalFormatterCb : ( numThreads : number ) => Promise < string [ ] > , formatEmbeddedCb : ( options : Record < string , any > , code : string ) => Promise < string > , formatFileCb : ( options : Record < string , any > , code : string ) => Promise < string > , sortTailwindClassesCb : ( options : Record < string , any > , classes : string [ ] ) => Promise < string [ ] > ) : Promise < FormatResult >
37+ export declare function format ( filename : string , sourceText : string , options : any | undefined | null , initExternalFormatterCb : ( numThreads : number ) => Promise < string [ ] > , formatEmbeddedCb : ( options : Record < string , any > , code : string ) => Promise < string > , formatEmbeddedDocCb : ( options : Record < string , any > , texts : string [ ] ) => Promise < string [ ] > , formatFileCb : ( options : Record < string , any > , code : string ) => Promise < string > , sortTailwindClassesCb : ( options : Record < string , any > , classes : string [ ] ) => Promise < string [ ] > ) : Promise < FormatResult >
3838
3939export interface FormatResult {
4040 /** The formatted code. */
@@ -49,7 +49,7 @@ export interface FormatResult {
4949 * This API is specialized for JS/TS snippets embedded in non-JS files.
5050 * Unlike `format()`, it is called only for js-in-xxx `textToDoc()` flow.
5151 */
52- export declare function jsTextToDoc ( sourceExt : string , sourceText : string , oxfmtPluginOptionsJson : string , parentContext : string , initExternalFormatterCb : ( numThreads : number ) => Promise < string [ ] > , formatEmbeddedCb : ( options : Record < string , any > , code : string ) => Promise < string > , formatFileCb : ( options : Record < string , any > , code : string ) => Promise < string > , sortTailwindClassesCb : ( options : Record < string , any > , classes : string [ ] ) => Promise < string [ ] > ) : Promise < string | null >
52+ export declare function jsTextToDoc ( sourceExt : string , sourceText : string , oxfmtPluginOptionsJson : string , parentContext : string , initExternalFormatterCb : ( numThreads : number ) => Promise < string [ ] > , formatEmbeddedCb : ( options : Record < string , any > , code : string ) => Promise < string > , formatEmbeddedDocCb : ( options : Record < string , any > , texts : string [ ] ) => Promise < string [ ] > , formatFileCb : ( options : Record < string , any > , code : string ) => Promise < string > , sortTailwindClassesCb : ( options : Record < string , any > , classes : string [ ] ) => Promise < string [ ] > ) : Promise < string | null >
5353
5454/**
5555 * NAPI based JS CLI entry point.
@@ -66,4 +66,4 @@ export declare function jsTextToDoc(sourceExt: string, sourceText: string, oxfmt
6666 * - `mode`: If main logic will run in JS side, use this to indicate which mode
6767 * - `exitCode`: If main logic already ran in Rust side, return the exit code
6868 */
69- export declare function runCli ( args : Array < string > , initExternalFormatterCb : ( numThreads : number ) => Promise < string [ ] > , formatEmbeddedCb : ( options : Record < string , any > , code : string ) => Promise < string > , formatFileCb : ( options : Record < string , any > , code : string ) => Promise < string > , sortTailwindcssClassesCb : ( options : Record < string , any > , classes : string [ ] ) => Promise < string [ ] > ) : Promise < [ string , number | undefined | null ] >
69+ export declare function runCli ( args : Array < string > , initExternalFormatterCb : ( numThreads : number ) => Promise < string [ ] > , formatEmbeddedCb : ( options : Record < string , any > , code : string ) => Promise < string > , formatEmbeddedDocCb : ( options : Record < string , any > , texts : string [ ] ) => Promise < string [ ] > , formatFileCb : ( options : Record < string , any > , code : string ) => Promise < string > , sortTailwindcssClassesCb : ( options : Record < string , any > , classes : string [ ] ) => Promise < string [ ] > ) : Promise < [ string , number | undefined | null ] >
0 commit comments