@biomejs/wasm-web 2.3.2 → 2.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/biome_wasm.d.ts +88 -44
- package/biome_wasm.js +170 -170
- package/biome_wasm_bg.wasm +0 -0
- package/package.json +1 -1
package/biome_wasm.d.ts
CHANGED
|
@@ -137,7 +137,7 @@ interface CssConfiguration {
|
|
|
137
137
|
type Extends = string[] | string;
|
|
138
138
|
interface FilesConfiguration {
|
|
139
139
|
/**
|
|
140
|
-
* **Deprecated:** Please use _force-ignore syntax_ in `files.includes` instead: https://biomejs.dev/reference/configuration/#filesincludes
|
|
140
|
+
* **Deprecated:** Please use _force-ignore syntax_ in `files.includes` instead: <https://biomejs.dev/reference/configuration/#filesincludes>
|
|
141
141
|
|
|
142
142
|
Set of file and folder names that should be unconditionally ignored by Biome's scanner.
|
|
143
143
|
*/
|
|
@@ -1549,6 +1549,10 @@ interface Nursery {
|
|
|
1549
1549
|
* Prevent client components from being async functions.
|
|
1550
1550
|
*/
|
|
1551
1551
|
noNextAsyncClientComponent?: RuleConfiguration_for_NoNextAsyncClientComponentOptions;
|
|
1552
|
+
/**
|
|
1553
|
+
* Disallow function parameters that are only used in recursive calls.
|
|
1554
|
+
*/
|
|
1555
|
+
noParametersOnlyUsedInRecursion?: RuleFixConfiguration_for_NoParametersOnlyUsedInRecursionOptions;
|
|
1552
1556
|
/**
|
|
1553
1557
|
* Replaces usages of forwardRef with passing ref as a prop.
|
|
1554
1558
|
*/
|
|
@@ -1557,6 +1561,10 @@ interface Nursery {
|
|
|
1557
1561
|
* Disallow variable declarations from shadowing variables declared in the outer scope.
|
|
1558
1562
|
*/
|
|
1559
1563
|
noShadow?: RuleConfiguration_for_NoShadowOptions;
|
|
1564
|
+
/**
|
|
1565
|
+
* Disallow unknown DOM properties.
|
|
1566
|
+
*/
|
|
1567
|
+
noUnknownAttribute?: RuleConfiguration_for_NoUnknownAttributeOptions;
|
|
1560
1568
|
/**
|
|
1561
1569
|
* Disallow unnecessary type-based conditions that can be statically determined as redundant.
|
|
1562
1570
|
*/
|
|
@@ -2914,12 +2922,18 @@ type RuleFixConfiguration_for_NoMisusedPromisesOptions =
|
|
|
2914
2922
|
type RuleConfiguration_for_NoNextAsyncClientComponentOptions =
|
|
2915
2923
|
| RulePlainConfiguration
|
|
2916
2924
|
| RuleWithOptions_for_NoNextAsyncClientComponentOptions;
|
|
2925
|
+
type RuleFixConfiguration_for_NoParametersOnlyUsedInRecursionOptions =
|
|
2926
|
+
| RulePlainConfiguration
|
|
2927
|
+
| RuleWithFixOptions_for_NoParametersOnlyUsedInRecursionOptions;
|
|
2917
2928
|
type RuleFixConfiguration_for_NoReactForwardRefOptions =
|
|
2918
2929
|
| RulePlainConfiguration
|
|
2919
2930
|
| RuleWithFixOptions_for_NoReactForwardRefOptions;
|
|
2920
2931
|
type RuleConfiguration_for_NoShadowOptions =
|
|
2921
2932
|
| RulePlainConfiguration
|
|
2922
2933
|
| RuleWithOptions_for_NoShadowOptions;
|
|
2934
|
+
type RuleConfiguration_for_NoUnknownAttributeOptions =
|
|
2935
|
+
| RulePlainConfiguration
|
|
2936
|
+
| RuleWithOptions_for_NoUnknownAttributeOptions;
|
|
2923
2937
|
type RuleConfiguration_for_NoUnnecessaryConditionsOptions =
|
|
2924
2938
|
| RulePlainConfiguration
|
|
2925
2939
|
| RuleWithOptions_for_NoUnnecessaryConditionsOptions;
|
|
@@ -5402,6 +5416,20 @@ interface RuleWithOptions_for_NoNextAsyncClientComponentOptions {
|
|
|
5402
5416
|
*/
|
|
5403
5417
|
options: NoNextAsyncClientComponentOptions;
|
|
5404
5418
|
}
|
|
5419
|
+
interface RuleWithFixOptions_for_NoParametersOnlyUsedInRecursionOptions {
|
|
5420
|
+
/**
|
|
5421
|
+
* The kind of the code actions emitted by the rule
|
|
5422
|
+
*/
|
|
5423
|
+
fix?: FixKind;
|
|
5424
|
+
/**
|
|
5425
|
+
* The severity of the emitted diagnostics by the rule
|
|
5426
|
+
*/
|
|
5427
|
+
level: RulePlainConfiguration;
|
|
5428
|
+
/**
|
|
5429
|
+
* Rule's options
|
|
5430
|
+
*/
|
|
5431
|
+
options: NoParametersOnlyUsedInRecursionOptions;
|
|
5432
|
+
}
|
|
5405
5433
|
interface RuleWithFixOptions_for_NoReactForwardRefOptions {
|
|
5406
5434
|
/**
|
|
5407
5435
|
* The kind of the code actions emitted by the rule
|
|
@@ -5426,6 +5454,16 @@ interface RuleWithOptions_for_NoShadowOptions {
|
|
|
5426
5454
|
*/
|
|
5427
5455
|
options: NoShadowOptions;
|
|
5428
5456
|
}
|
|
5457
|
+
interface RuleWithOptions_for_NoUnknownAttributeOptions {
|
|
5458
|
+
/**
|
|
5459
|
+
* The severity of the emitted diagnostics by the rule
|
|
5460
|
+
*/
|
|
5461
|
+
level: RulePlainConfiguration;
|
|
5462
|
+
/**
|
|
5463
|
+
* Rule's options
|
|
5464
|
+
*/
|
|
5465
|
+
options: NoUnknownAttributeOptions;
|
|
5466
|
+
}
|
|
5429
5467
|
interface RuleWithOptions_for_NoUnnecessaryConditionsOptions {
|
|
5430
5468
|
/**
|
|
5431
5469
|
* The severity of the emitted diagnostics by the rule
|
|
@@ -8120,8 +8158,12 @@ interface NoJsxLiteralsOptions {
|
|
|
8120
8158
|
}
|
|
8121
8159
|
interface NoMisusedPromisesOptions {}
|
|
8122
8160
|
interface NoNextAsyncClientComponentOptions {}
|
|
8161
|
+
interface NoParametersOnlyUsedInRecursionOptions {}
|
|
8123
8162
|
interface NoReactForwardRefOptions {}
|
|
8124
8163
|
interface NoShadowOptions {}
|
|
8164
|
+
interface NoUnknownAttributeOptions {
|
|
8165
|
+
ignore: string[];
|
|
8166
|
+
}
|
|
8125
8167
|
interface NoUnnecessaryConditionsOptions {}
|
|
8126
8168
|
interface NoUnresolvedImportsOptions {}
|
|
8127
8169
|
interface NoUnusedExpressionsOptions {}
|
|
@@ -8861,8 +8903,10 @@ type Category =
|
|
|
8861
8903
|
| "lint/nursery/noMissingGenericFamilyKeyword"
|
|
8862
8904
|
| "lint/nursery/noMisusedPromises"
|
|
8863
8905
|
| "lint/nursery/noNextAsyncClientComponent"
|
|
8906
|
+
| "lint/nursery/noParametersOnlyUsedInRecursion"
|
|
8864
8907
|
| "lint/nursery/noReactForwardRef"
|
|
8865
8908
|
| "lint/nursery/noShadow"
|
|
8909
|
+
| "lint/nursery/noUnknownAttribute"
|
|
8866
8910
|
| "lint/nursery/noUnnecessaryConditions"
|
|
8867
8911
|
| "lint/nursery/noUnresolvedImports"
|
|
8868
8912
|
| "lint/nursery/noUnusedExpressions"
|
|
@@ -9621,9 +9665,9 @@ interface DropPatternParams {
|
|
|
9621
9665
|
export class DiagnosticPrinter {
|
|
9622
9666
|
free(): void;
|
|
9623
9667
|
[Symbol.dispose](): void;
|
|
9624
|
-
constructor(file_name: string, file_source: string);
|
|
9625
9668
|
print_simple(diagnostic: Diagnostic): void;
|
|
9626
9669
|
print_verbose(diagnostic: Diagnostic): void;
|
|
9670
|
+
constructor(file_name: string, file_source: string);
|
|
9627
9671
|
finish(): string;
|
|
9628
9672
|
}
|
|
9629
9673
|
export class MemoryFileSystem {
|
|
@@ -9636,33 +9680,33 @@ export class MemoryFileSystem {
|
|
|
9636
9680
|
export class Workspace {
|
|
9637
9681
|
free(): void;
|
|
9638
9682
|
[Symbol.dispose](): void;
|
|
9639
|
-
|
|
9640
|
-
|
|
9641
|
-
|
|
9642
|
-
|
|
9683
|
+
closeFile(params: CloseFileParams): void;
|
|
9684
|
+
changeFile(params: ChangeFileParams): ChangeFileResult;
|
|
9685
|
+
fileExists(params: FileExitsParams): boolean;
|
|
9686
|
+
formatFile(params: FormatFileParams): any;
|
|
9687
|
+
formatRange(params: FormatRangeParams): any;
|
|
9643
9688
|
openProject(params: OpenProjectParams): OpenProjectResult;
|
|
9689
|
+
pullActions(params: PullActionsParams): PullActionsResult;
|
|
9644
9690
|
scanProject(params: ScanProjectParams): ScanProjectResult;
|
|
9645
|
-
|
|
9646
|
-
getFileContent(params: GetFileContentParams): string;
|
|
9647
|
-
getSyntaxTree(params: GetSyntaxTreeParams): GetSyntaxTreeResult;
|
|
9648
|
-
getControlFlowGraph(params: GetControlFlowGraphParams): string;
|
|
9649
|
-
getFormatterIr(params: GetFormatterIRParams): string;
|
|
9691
|
+
fileFeatures(params: SupportsFeatureParams): FileFeaturesResult;
|
|
9650
9692
|
getTypeInfo(params: GetTypeInfoParams): string;
|
|
9651
|
-
|
|
9652
|
-
|
|
9653
|
-
changeFile(params: ChangeFileParams): ChangeFileResult;
|
|
9654
|
-
closeFile(params: CloseFileParams): void;
|
|
9655
|
-
fileExists(params: FileExitsParams): boolean;
|
|
9693
|
+
formatOnType(params: FormatOnTypeParams): any;
|
|
9694
|
+
getSyntaxTree(params: GetSyntaxTreeParams): GetSyntaxTreeResult;
|
|
9656
9695
|
isPathIgnored(params: PathIsIgnoredParams): boolean;
|
|
9657
|
-
|
|
9696
|
+
updateSettings(params: UpdateSettingsParams): UpdateSettingsResult;
|
|
9697
|
+
getFileContent(params: GetFileContentParams): string;
|
|
9698
|
+
getFormatterIr(params: GetFormatterIRParams): string;
|
|
9658
9699
|
getModuleGraph(params: GetModuleGraphParams): GetModuleGraphResult;
|
|
9659
9700
|
pullDiagnostics(params: PullDiagnosticsParams): PullDiagnosticsResult;
|
|
9660
|
-
|
|
9661
|
-
|
|
9662
|
-
|
|
9663
|
-
|
|
9664
|
-
|
|
9701
|
+
getSemanticModel(params: GetSemanticModelParams): string;
|
|
9702
|
+
static withFileSystem(fs: MemoryFileSystem): Workspace;
|
|
9703
|
+
updateModuleGraph(params: UpdateModuleGraphParams): void;
|
|
9704
|
+
getRegisteredTypes(params: GetRegisteredTypesParams): string;
|
|
9705
|
+
getControlFlowGraph(params: GetControlFlowGraphParams): string;
|
|
9706
|
+
constructor();
|
|
9665
9707
|
rename(params: RenameParams): RenameResult;
|
|
9708
|
+
fixFile(params: FixFileParams): FixFileResult;
|
|
9709
|
+
openFile(params: OpenFileParams): OpenFileResult;
|
|
9666
9710
|
}
|
|
9667
9711
|
|
|
9668
9712
|
export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
|
|
@@ -9670,43 +9714,43 @@ export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembl
|
|
|
9670
9714
|
export interface InitOutput {
|
|
9671
9715
|
readonly memory: WebAssembly.Memory;
|
|
9672
9716
|
readonly __wbg_memoryfilesystem_free: (a: number, b: number) => void;
|
|
9673
|
-
readonly
|
|
9717
|
+
readonly __wbg_workspace_free: (a: number, b: number) => void;
|
|
9674
9718
|
readonly memoryfilesystem_insert: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
9719
|
+
readonly memoryfilesystem_new: () => number;
|
|
9675
9720
|
readonly memoryfilesystem_remove: (a: number, b: number, c: number) => void;
|
|
9676
|
-
readonly
|
|
9677
|
-
readonly
|
|
9678
|
-
readonly
|
|
9721
|
+
readonly workspace_changeFile: (a: number, b: any) => [number, number, number];
|
|
9722
|
+
readonly workspace_closeFile: (a: number, b: any) => [number, number];
|
|
9723
|
+
readonly workspace_fileExists: (a: number, b: any) => [number, number, number];
|
|
9679
9724
|
readonly workspace_fileFeatures: (a: number, b: any) => [number, number, number];
|
|
9680
|
-
readonly
|
|
9681
|
-
readonly
|
|
9682
|
-
readonly
|
|
9683
|
-
readonly
|
|
9684
|
-
readonly workspace_getFileContent: (a: number, b: any) => [number, number, number, number];
|
|
9685
|
-
readonly workspace_getSyntaxTree: (a: number, b: any) => [number, number, number];
|
|
9725
|
+
readonly workspace_fixFile: (a: number, b: any) => [number, number, number];
|
|
9726
|
+
readonly workspace_formatFile: (a: number, b: any) => [number, number, number];
|
|
9727
|
+
readonly workspace_formatOnType: (a: number, b: any) => [number, number, number];
|
|
9728
|
+
readonly workspace_formatRange: (a: number, b: any) => [number, number, number];
|
|
9686
9729
|
readonly workspace_getControlFlowGraph: (a: number, b: any) => [number, number, number, number];
|
|
9730
|
+
readonly workspace_getFileContent: (a: number, b: any) => [number, number, number, number];
|
|
9687
9731
|
readonly workspace_getFormatterIr: (a: number, b: any) => [number, number, number, number];
|
|
9688
|
-
readonly
|
|
9732
|
+
readonly workspace_getModuleGraph: (a: number, b: any) => [number, number, number];
|
|
9689
9733
|
readonly workspace_getRegisteredTypes: (a: number, b: any) => [number, number, number, number];
|
|
9690
9734
|
readonly workspace_getSemanticModel: (a: number, b: any) => [number, number, number, number];
|
|
9691
|
-
readonly
|
|
9692
|
-
readonly
|
|
9693
|
-
readonly workspace_fileExists: (a: number, b: any) => [number, number, number];
|
|
9735
|
+
readonly workspace_getSyntaxTree: (a: number, b: any) => [number, number, number];
|
|
9736
|
+
readonly workspace_getTypeInfo: (a: number, b: any) => [number, number, number, number];
|
|
9694
9737
|
readonly workspace_isPathIgnored: (a: number, b: any) => [number, number, number];
|
|
9695
|
-
readonly
|
|
9696
|
-
readonly
|
|
9697
|
-
readonly
|
|
9738
|
+
readonly workspace_new: () => number;
|
|
9739
|
+
readonly workspace_openFile: (a: number, b: any) => [number, number, number];
|
|
9740
|
+
readonly workspace_openProject: (a: number, b: any) => [number, number, number];
|
|
9698
9741
|
readonly workspace_pullActions: (a: number, b: any) => [number, number, number];
|
|
9699
|
-
readonly
|
|
9700
|
-
readonly workspace_formatRange: (a: number, b: any) => [number, number, number];
|
|
9701
|
-
readonly workspace_formatOnType: (a: number, b: any) => [number, number, number];
|
|
9702
|
-
readonly workspace_fixFile: (a: number, b: any) => [number, number, number];
|
|
9742
|
+
readonly workspace_pullDiagnostics: (a: number, b: any) => [number, number, number];
|
|
9703
9743
|
readonly workspace_rename: (a: number, b: any) => [number, number, number];
|
|
9744
|
+
readonly workspace_scanProject: (a: number, b: any) => [number, number, number];
|
|
9745
|
+
readonly workspace_updateModuleGraph: (a: number, b: any) => [number, number];
|
|
9746
|
+
readonly workspace_updateSettings: (a: number, b: any) => [number, number, number];
|
|
9747
|
+
readonly workspace_withFileSystem: (a: number) => number;
|
|
9704
9748
|
readonly main: () => void;
|
|
9705
9749
|
readonly __wbg_diagnosticprinter_free: (a: number, b: number) => void;
|
|
9750
|
+
readonly diagnosticprinter_finish: (a: number) => [number, number, number, number];
|
|
9706
9751
|
readonly diagnosticprinter_new: (a: number, b: number, c: number, d: number) => number;
|
|
9707
9752
|
readonly diagnosticprinter_print_simple: (a: number, b: any) => [number, number];
|
|
9708
9753
|
readonly diagnosticprinter_print_verbose: (a: number, b: any) => [number, number];
|
|
9709
|
-
readonly diagnosticprinter_finish: (a: number) => [number, number, number, number];
|
|
9710
9754
|
readonly __wbindgen_malloc: (a: number, b: number) => number;
|
|
9711
9755
|
readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
|
|
9712
9756
|
readonly __wbindgen_exn_store: (a: number) => void;
|
package/biome_wasm.js
CHANGED
|
@@ -182,10 +182,6 @@ function debugString(val) {
|
|
|
182
182
|
return className;
|
|
183
183
|
}
|
|
184
184
|
|
|
185
|
-
export function main() {
|
|
186
|
-
wasm.main();
|
|
187
|
-
}
|
|
188
|
-
|
|
189
185
|
function passArray8ToWasm0(arg, malloc) {
|
|
190
186
|
const ptr = malloc(arg.length * 1, 1) >>> 0;
|
|
191
187
|
getUint8ArrayMemory0().set(arg, ptr / 1);
|
|
@@ -193,10 +189,8 @@ function passArray8ToWasm0(arg, malloc) {
|
|
|
193
189
|
return ptr;
|
|
194
190
|
}
|
|
195
191
|
|
|
196
|
-
function
|
|
197
|
-
|
|
198
|
-
throw new Error(`expected instance of ${klass.name}`);
|
|
199
|
-
}
|
|
192
|
+
export function main() {
|
|
193
|
+
wasm.main();
|
|
200
194
|
}
|
|
201
195
|
|
|
202
196
|
function takeFromExternrefTable0(idx) {
|
|
@@ -205,6 +199,12 @@ function takeFromExternrefTable0(idx) {
|
|
|
205
199
|
return value;
|
|
206
200
|
}
|
|
207
201
|
|
|
202
|
+
function _assertClass(instance, klass) {
|
|
203
|
+
if (!(instance instanceof klass)) {
|
|
204
|
+
throw new Error(`expected instance of ${klass.name}`);
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
|
|
208
208
|
const DiagnosticPrinterFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
209
209
|
? { register: () => {}, unregister: () => {} }
|
|
210
210
|
: new FinalizationRegistry(ptr => wasm.__wbg_diagnosticprinter_free(ptr >>> 0, 1));
|
|
@@ -222,20 +222,6 @@ export class DiagnosticPrinter {
|
|
|
222
222
|
const ptr = this.__destroy_into_raw();
|
|
223
223
|
wasm.__wbg_diagnosticprinter_free(ptr, 0);
|
|
224
224
|
}
|
|
225
|
-
/**
|
|
226
|
-
* @param {string} file_name
|
|
227
|
-
* @param {string} file_source
|
|
228
|
-
*/
|
|
229
|
-
constructor(file_name, file_source) {
|
|
230
|
-
const ptr0 = passStringToWasm0(file_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
231
|
-
const len0 = WASM_VECTOR_LEN;
|
|
232
|
-
const ptr1 = passStringToWasm0(file_source, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
233
|
-
const len1 = WASM_VECTOR_LEN;
|
|
234
|
-
const ret = wasm.diagnosticprinter_new(ptr0, len0, ptr1, len1);
|
|
235
|
-
this.__wbg_ptr = ret >>> 0;
|
|
236
|
-
DiagnosticPrinterFinalization.register(this, this.__wbg_ptr, this);
|
|
237
|
-
return this;
|
|
238
|
-
}
|
|
239
225
|
/**
|
|
240
226
|
* @param {Diagnostic} diagnostic
|
|
241
227
|
*/
|
|
@@ -254,6 +240,20 @@ export class DiagnosticPrinter {
|
|
|
254
240
|
throw takeFromExternrefTable0(ret[0]);
|
|
255
241
|
}
|
|
256
242
|
}
|
|
243
|
+
/**
|
|
244
|
+
* @param {string} file_name
|
|
245
|
+
* @param {string} file_source
|
|
246
|
+
*/
|
|
247
|
+
constructor(file_name, file_source) {
|
|
248
|
+
const ptr0 = passStringToWasm0(file_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
249
|
+
const len0 = WASM_VECTOR_LEN;
|
|
250
|
+
const ptr1 = passStringToWasm0(file_source, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
251
|
+
const len1 = WASM_VECTOR_LEN;
|
|
252
|
+
const ret = wasm.diagnosticprinter_new(ptr0, len0, ptr1, len1);
|
|
253
|
+
this.__wbg_ptr = ret >>> 0;
|
|
254
|
+
DiagnosticPrinterFinalization.register(this, this.__wbg_ptr, this);
|
|
255
|
+
return this;
|
|
256
|
+
}
|
|
257
257
|
/**
|
|
258
258
|
* @returns {string}
|
|
259
259
|
*/
|
|
@@ -349,38 +349,54 @@ export class Workspace {
|
|
|
349
349
|
const ptr = this.__destroy_into_raw();
|
|
350
350
|
wasm.__wbg_workspace_free(ptr, 0);
|
|
351
351
|
}
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
352
|
+
/**
|
|
353
|
+
* @param {CloseFileParams} params
|
|
354
|
+
*/
|
|
355
|
+
closeFile(params) {
|
|
356
|
+
const ret = wasm.workspace_closeFile(this.__wbg_ptr, params);
|
|
357
|
+
if (ret[1]) {
|
|
358
|
+
throw takeFromExternrefTable0(ret[0]);
|
|
359
|
+
}
|
|
357
360
|
}
|
|
358
361
|
/**
|
|
359
|
-
* @param {
|
|
360
|
-
* @returns {
|
|
362
|
+
* @param {ChangeFileParams} params
|
|
363
|
+
* @returns {ChangeFileResult}
|
|
361
364
|
*/
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
365
|
+
changeFile(params) {
|
|
366
|
+
const ret = wasm.workspace_changeFile(this.__wbg_ptr, params);
|
|
367
|
+
if (ret[2]) {
|
|
368
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
369
|
+
}
|
|
370
|
+
return takeFromExternrefTable0(ret[0]);
|
|
366
371
|
}
|
|
367
372
|
/**
|
|
368
|
-
* @param {
|
|
369
|
-
* @returns {
|
|
373
|
+
* @param {FileExitsParams} params
|
|
374
|
+
* @returns {boolean}
|
|
370
375
|
*/
|
|
371
|
-
|
|
372
|
-
const ret = wasm.
|
|
376
|
+
fileExists(params) {
|
|
377
|
+
const ret = wasm.workspace_fileExists(this.__wbg_ptr, params);
|
|
378
|
+
if (ret[2]) {
|
|
379
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
380
|
+
}
|
|
381
|
+
return ret[0] !== 0;
|
|
382
|
+
}
|
|
383
|
+
/**
|
|
384
|
+
* @param {FormatFileParams} params
|
|
385
|
+
* @returns {any}
|
|
386
|
+
*/
|
|
387
|
+
formatFile(params) {
|
|
388
|
+
const ret = wasm.workspace_formatFile(this.__wbg_ptr, params);
|
|
373
389
|
if (ret[2]) {
|
|
374
390
|
throw takeFromExternrefTable0(ret[1]);
|
|
375
391
|
}
|
|
376
392
|
return takeFromExternrefTable0(ret[0]);
|
|
377
393
|
}
|
|
378
394
|
/**
|
|
379
|
-
* @param {
|
|
380
|
-
* @returns {
|
|
395
|
+
* @param {FormatRangeParams} params
|
|
396
|
+
* @returns {any}
|
|
381
397
|
*/
|
|
382
|
-
|
|
383
|
-
const ret = wasm.
|
|
398
|
+
formatRange(params) {
|
|
399
|
+
const ret = wasm.workspace_formatRange(this.__wbg_ptr, params);
|
|
384
400
|
if (ret[2]) {
|
|
385
401
|
throw takeFromExternrefTable0(ret[1]);
|
|
386
402
|
}
|
|
@@ -397,6 +413,17 @@ export class Workspace {
|
|
|
397
413
|
}
|
|
398
414
|
return takeFromExternrefTable0(ret[0]);
|
|
399
415
|
}
|
|
416
|
+
/**
|
|
417
|
+
* @param {PullActionsParams} params
|
|
418
|
+
* @returns {PullActionsResult}
|
|
419
|
+
*/
|
|
420
|
+
pullActions(params) {
|
|
421
|
+
const ret = wasm.workspace_pullActions(this.__wbg_ptr, params);
|
|
422
|
+
if (ret[2]) {
|
|
423
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
424
|
+
}
|
|
425
|
+
return takeFromExternrefTable0(ret[0]);
|
|
426
|
+
}
|
|
400
427
|
/**
|
|
401
428
|
* @param {ScanProjectParams} params
|
|
402
429
|
* @returns {ScanProjectResult}
|
|
@@ -409,25 +436,25 @@ export class Workspace {
|
|
|
409
436
|
return takeFromExternrefTable0(ret[0]);
|
|
410
437
|
}
|
|
411
438
|
/**
|
|
412
|
-
* @param {
|
|
413
|
-
* @returns {
|
|
439
|
+
* @param {SupportsFeatureParams} params
|
|
440
|
+
* @returns {FileFeaturesResult}
|
|
414
441
|
*/
|
|
415
|
-
|
|
416
|
-
const ret = wasm.
|
|
442
|
+
fileFeatures(params) {
|
|
443
|
+
const ret = wasm.workspace_fileFeatures(this.__wbg_ptr, params);
|
|
417
444
|
if (ret[2]) {
|
|
418
445
|
throw takeFromExternrefTable0(ret[1]);
|
|
419
446
|
}
|
|
420
447
|
return takeFromExternrefTable0(ret[0]);
|
|
421
448
|
}
|
|
422
449
|
/**
|
|
423
|
-
* @param {
|
|
450
|
+
* @param {GetTypeInfoParams} params
|
|
424
451
|
* @returns {string}
|
|
425
452
|
*/
|
|
426
|
-
|
|
453
|
+
getTypeInfo(params) {
|
|
427
454
|
let deferred2_0;
|
|
428
455
|
let deferred2_1;
|
|
429
456
|
try {
|
|
430
|
-
const ret = wasm.
|
|
457
|
+
const ret = wasm.workspace_getTypeInfo(this.__wbg_ptr, params);
|
|
431
458
|
var ptr1 = ret[0];
|
|
432
459
|
var len1 = ret[1];
|
|
433
460
|
if (ret[3]) {
|
|
@@ -441,6 +468,17 @@ export class Workspace {
|
|
|
441
468
|
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
442
469
|
}
|
|
443
470
|
}
|
|
471
|
+
/**
|
|
472
|
+
* @param {FormatOnTypeParams} params
|
|
473
|
+
* @returns {any}
|
|
474
|
+
*/
|
|
475
|
+
formatOnType(params) {
|
|
476
|
+
const ret = wasm.workspace_formatOnType(this.__wbg_ptr, params);
|
|
477
|
+
if (ret[2]) {
|
|
478
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
479
|
+
}
|
|
480
|
+
return takeFromExternrefTable0(ret[0]);
|
|
481
|
+
}
|
|
444
482
|
/**
|
|
445
483
|
* @param {GetSyntaxTreeParams} params
|
|
446
484
|
* @returns {GetSyntaxTreeResult}
|
|
@@ -453,14 +491,36 @@ export class Workspace {
|
|
|
453
491
|
return takeFromExternrefTable0(ret[0]);
|
|
454
492
|
}
|
|
455
493
|
/**
|
|
456
|
-
* @param {
|
|
494
|
+
* @param {PathIsIgnoredParams} params
|
|
495
|
+
* @returns {boolean}
|
|
496
|
+
*/
|
|
497
|
+
isPathIgnored(params) {
|
|
498
|
+
const ret = wasm.workspace_isPathIgnored(this.__wbg_ptr, params);
|
|
499
|
+
if (ret[2]) {
|
|
500
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
501
|
+
}
|
|
502
|
+
return ret[0] !== 0;
|
|
503
|
+
}
|
|
504
|
+
/**
|
|
505
|
+
* @param {UpdateSettingsParams} params
|
|
506
|
+
* @returns {UpdateSettingsResult}
|
|
507
|
+
*/
|
|
508
|
+
updateSettings(params) {
|
|
509
|
+
const ret = wasm.workspace_updateSettings(this.__wbg_ptr, params);
|
|
510
|
+
if (ret[2]) {
|
|
511
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
512
|
+
}
|
|
513
|
+
return takeFromExternrefTable0(ret[0]);
|
|
514
|
+
}
|
|
515
|
+
/**
|
|
516
|
+
* @param {GetFileContentParams} params
|
|
457
517
|
* @returns {string}
|
|
458
518
|
*/
|
|
459
|
-
|
|
519
|
+
getFileContent(params) {
|
|
460
520
|
let deferred2_0;
|
|
461
521
|
let deferred2_1;
|
|
462
522
|
try {
|
|
463
|
-
const ret = wasm.
|
|
523
|
+
const ret = wasm.workspace_getFileContent(this.__wbg_ptr, params);
|
|
464
524
|
var ptr1 = ret[0];
|
|
465
525
|
var len1 = ret[1];
|
|
466
526
|
if (ret[3]) {
|
|
@@ -497,14 +557,36 @@ export class Workspace {
|
|
|
497
557
|
}
|
|
498
558
|
}
|
|
499
559
|
/**
|
|
500
|
-
* @param {
|
|
560
|
+
* @param {GetModuleGraphParams} params
|
|
561
|
+
* @returns {GetModuleGraphResult}
|
|
562
|
+
*/
|
|
563
|
+
getModuleGraph(params) {
|
|
564
|
+
const ret = wasm.workspace_getModuleGraph(this.__wbg_ptr, params);
|
|
565
|
+
if (ret[2]) {
|
|
566
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
567
|
+
}
|
|
568
|
+
return takeFromExternrefTable0(ret[0]);
|
|
569
|
+
}
|
|
570
|
+
/**
|
|
571
|
+
* @param {PullDiagnosticsParams} params
|
|
572
|
+
* @returns {PullDiagnosticsResult}
|
|
573
|
+
*/
|
|
574
|
+
pullDiagnostics(params) {
|
|
575
|
+
const ret = wasm.workspace_pullDiagnostics(this.__wbg_ptr, params);
|
|
576
|
+
if (ret[2]) {
|
|
577
|
+
throw takeFromExternrefTable0(ret[1]);
|
|
578
|
+
}
|
|
579
|
+
return takeFromExternrefTable0(ret[0]);
|
|
580
|
+
}
|
|
581
|
+
/**
|
|
582
|
+
* @param {GetSemanticModelParams} params
|
|
501
583
|
* @returns {string}
|
|
502
584
|
*/
|
|
503
|
-
|
|
585
|
+
getSemanticModel(params) {
|
|
504
586
|
let deferred2_0;
|
|
505
587
|
let deferred2_1;
|
|
506
588
|
try {
|
|
507
|
-
const ret = wasm.
|
|
589
|
+
const ret = wasm.workspace_getSemanticModel(this.__wbg_ptr, params);
|
|
508
590
|
var ptr1 = ret[0];
|
|
509
591
|
var len1 = ret[1];
|
|
510
592
|
if (ret[3]) {
|
|
@@ -518,6 +600,24 @@ export class Workspace {
|
|
|
518
600
|
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
519
601
|
}
|
|
520
602
|
}
|
|
603
|
+
/**
|
|
604
|
+
* @param {MemoryFileSystem} fs
|
|
605
|
+
* @returns {Workspace}
|
|
606
|
+
*/
|
|
607
|
+
static withFileSystem(fs) {
|
|
608
|
+
_assertClass(fs, MemoryFileSystem);
|
|
609
|
+
const ret = wasm.workspace_withFileSystem(fs.__wbg_ptr);
|
|
610
|
+
return Workspace.__wrap(ret);
|
|
611
|
+
}
|
|
612
|
+
/**
|
|
613
|
+
* @param {UpdateModuleGraphParams} params
|
|
614
|
+
*/
|
|
615
|
+
updateModuleGraph(params) {
|
|
616
|
+
const ret = wasm.workspace_updateModuleGraph(this.__wbg_ptr, params);
|
|
617
|
+
if (ret[1]) {
|
|
618
|
+
throw takeFromExternrefTable0(ret[0]);
|
|
619
|
+
}
|
|
620
|
+
}
|
|
521
621
|
/**
|
|
522
622
|
* @param {GetRegisteredTypesParams} params
|
|
523
623
|
* @returns {string}
|
|
@@ -541,14 +641,14 @@ export class Workspace {
|
|
|
541
641
|
}
|
|
542
642
|
}
|
|
543
643
|
/**
|
|
544
|
-
* @param {
|
|
644
|
+
* @param {GetControlFlowGraphParams} params
|
|
545
645
|
* @returns {string}
|
|
546
646
|
*/
|
|
547
|
-
|
|
647
|
+
getControlFlowGraph(params) {
|
|
548
648
|
let deferred2_0;
|
|
549
649
|
let deferred2_1;
|
|
550
650
|
try {
|
|
551
|
-
const ret = wasm.
|
|
651
|
+
const ret = wasm.workspace_getControlFlowGraph(this.__wbg_ptr, params);
|
|
552
652
|
var ptr1 = ret[0];
|
|
553
653
|
var len1 = ret[1];
|
|
554
654
|
if (ret[3]) {
|
|
@@ -562,118 +662,18 @@ export class Workspace {
|
|
|
562
662
|
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
563
663
|
}
|
|
564
664
|
}
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
const ret = wasm.workspace_changeFile(this.__wbg_ptr, params);
|
|
571
|
-
if (ret[2]) {
|
|
572
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
573
|
-
}
|
|
574
|
-
return takeFromExternrefTable0(ret[0]);
|
|
575
|
-
}
|
|
576
|
-
/**
|
|
577
|
-
* @param {CloseFileParams} params
|
|
578
|
-
*/
|
|
579
|
-
closeFile(params) {
|
|
580
|
-
const ret = wasm.workspace_closeFile(this.__wbg_ptr, params);
|
|
581
|
-
if (ret[1]) {
|
|
582
|
-
throw takeFromExternrefTable0(ret[0]);
|
|
583
|
-
}
|
|
584
|
-
}
|
|
585
|
-
/**
|
|
586
|
-
* @param {FileExitsParams} params
|
|
587
|
-
* @returns {boolean}
|
|
588
|
-
*/
|
|
589
|
-
fileExists(params) {
|
|
590
|
-
const ret = wasm.workspace_fileExists(this.__wbg_ptr, params);
|
|
591
|
-
if (ret[2]) {
|
|
592
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
593
|
-
}
|
|
594
|
-
return ret[0] !== 0;
|
|
595
|
-
}
|
|
596
|
-
/**
|
|
597
|
-
* @param {PathIsIgnoredParams} params
|
|
598
|
-
* @returns {boolean}
|
|
599
|
-
*/
|
|
600
|
-
isPathIgnored(params) {
|
|
601
|
-
const ret = wasm.workspace_isPathIgnored(this.__wbg_ptr, params);
|
|
602
|
-
if (ret[2]) {
|
|
603
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
604
|
-
}
|
|
605
|
-
return ret[0] !== 0;
|
|
606
|
-
}
|
|
607
|
-
/**
|
|
608
|
-
* @param {UpdateModuleGraphParams} params
|
|
609
|
-
*/
|
|
610
|
-
updateModuleGraph(params) {
|
|
611
|
-
const ret = wasm.workspace_updateModuleGraph(this.__wbg_ptr, params);
|
|
612
|
-
if (ret[1]) {
|
|
613
|
-
throw takeFromExternrefTable0(ret[0]);
|
|
614
|
-
}
|
|
615
|
-
}
|
|
616
|
-
/**
|
|
617
|
-
* @param {GetModuleGraphParams} params
|
|
618
|
-
* @returns {GetModuleGraphResult}
|
|
619
|
-
*/
|
|
620
|
-
getModuleGraph(params) {
|
|
621
|
-
const ret = wasm.workspace_getModuleGraph(this.__wbg_ptr, params);
|
|
622
|
-
if (ret[2]) {
|
|
623
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
624
|
-
}
|
|
625
|
-
return takeFromExternrefTable0(ret[0]);
|
|
626
|
-
}
|
|
627
|
-
/**
|
|
628
|
-
* @param {PullDiagnosticsParams} params
|
|
629
|
-
* @returns {PullDiagnosticsResult}
|
|
630
|
-
*/
|
|
631
|
-
pullDiagnostics(params) {
|
|
632
|
-
const ret = wasm.workspace_pullDiagnostics(this.__wbg_ptr, params);
|
|
633
|
-
if (ret[2]) {
|
|
634
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
635
|
-
}
|
|
636
|
-
return takeFromExternrefTable0(ret[0]);
|
|
637
|
-
}
|
|
638
|
-
/**
|
|
639
|
-
* @param {PullActionsParams} params
|
|
640
|
-
* @returns {PullActionsResult}
|
|
641
|
-
*/
|
|
642
|
-
pullActions(params) {
|
|
643
|
-
const ret = wasm.workspace_pullActions(this.__wbg_ptr, params);
|
|
644
|
-
if (ret[2]) {
|
|
645
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
646
|
-
}
|
|
647
|
-
return takeFromExternrefTable0(ret[0]);
|
|
648
|
-
}
|
|
649
|
-
/**
|
|
650
|
-
* @param {FormatFileParams} params
|
|
651
|
-
* @returns {any}
|
|
652
|
-
*/
|
|
653
|
-
formatFile(params) {
|
|
654
|
-
const ret = wasm.workspace_formatFile(this.__wbg_ptr, params);
|
|
655
|
-
if (ret[2]) {
|
|
656
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
657
|
-
}
|
|
658
|
-
return takeFromExternrefTable0(ret[0]);
|
|
659
|
-
}
|
|
660
|
-
/**
|
|
661
|
-
* @param {FormatRangeParams} params
|
|
662
|
-
* @returns {any}
|
|
663
|
-
*/
|
|
664
|
-
formatRange(params) {
|
|
665
|
-
const ret = wasm.workspace_formatRange(this.__wbg_ptr, params);
|
|
666
|
-
if (ret[2]) {
|
|
667
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
668
|
-
}
|
|
669
|
-
return takeFromExternrefTable0(ret[0]);
|
|
665
|
+
constructor() {
|
|
666
|
+
const ret = wasm.workspace_new();
|
|
667
|
+
this.__wbg_ptr = ret >>> 0;
|
|
668
|
+
WorkspaceFinalization.register(this, this.__wbg_ptr, this);
|
|
669
|
+
return this;
|
|
670
670
|
}
|
|
671
671
|
/**
|
|
672
|
-
* @param {
|
|
673
|
-
* @returns {
|
|
672
|
+
* @param {RenameParams} params
|
|
673
|
+
* @returns {RenameResult}
|
|
674
674
|
*/
|
|
675
|
-
|
|
676
|
-
const ret = wasm.
|
|
675
|
+
rename(params) {
|
|
676
|
+
const ret = wasm.workspace_rename(this.__wbg_ptr, params);
|
|
677
677
|
if (ret[2]) {
|
|
678
678
|
throw takeFromExternrefTable0(ret[1]);
|
|
679
679
|
}
|
|
@@ -691,11 +691,11 @@ export class Workspace {
|
|
|
691
691
|
return takeFromExternrefTable0(ret[0]);
|
|
692
692
|
}
|
|
693
693
|
/**
|
|
694
|
-
* @param {
|
|
695
|
-
* @returns {
|
|
694
|
+
* @param {OpenFileParams} params
|
|
695
|
+
* @returns {OpenFileResult}
|
|
696
696
|
*/
|
|
697
|
-
|
|
698
|
-
const ret = wasm.
|
|
697
|
+
openFile(params) {
|
|
698
|
+
const ret = wasm.workspace_openFile(this.__wbg_ptr, params);
|
|
699
699
|
if (ret[2]) {
|
|
700
700
|
throw takeFromExternrefTable0(ret[1]);
|
|
701
701
|
}
|
package/biome_wasm_bg.wasm
CHANGED
|
Binary file
|