oxfmt 0.40.0 → 0.41.0

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.
@@ -104,7 +104,7 @@ async function sortTailwindClasses({ classes, options }) {
104
104
  let oxfmtPluginCache;
105
105
  async function loadOxfmtPlugin() {
106
106
  if (oxfmtPluginCache) return oxfmtPluginCache;
107
- oxfmtPluginCache = await import("./prettier-plugin-oxfmt-gZr3rMg5.js");
107
+ oxfmtPluginCache = await import("./prettier-plugin-oxfmt-BqWJLUOn.js");
108
108
  return oxfmtPluginCache;
109
109
  }
110
110
  /**
@@ -57,7 +57,7 @@ function requireNative() {
57
57
  try {
58
58
  const binding = require("@oxfmt/binding-android-arm64");
59
59
  const bindingPackageVersion = require("@oxfmt/binding-android-arm64/package.json").version;
60
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
60
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
61
61
  return binding;
62
62
  } catch (e) {
63
63
  loadErrors.push(e);
@@ -71,7 +71,7 @@ function requireNative() {
71
71
  try {
72
72
  const binding = require("@oxfmt/binding-android-arm-eabi");
73
73
  const bindingPackageVersion = require("@oxfmt/binding-android-arm-eabi/package.json").version;
74
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
74
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
75
75
  return binding;
76
76
  } catch (e) {
77
77
  loadErrors.push(e);
@@ -86,7 +86,7 @@ function requireNative() {
86
86
  try {
87
87
  const binding = require("@oxfmt/binding-win32-x64-gnu");
88
88
  const bindingPackageVersion = require("@oxfmt/binding-win32-x64-gnu/package.json").version;
89
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
89
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
90
90
  return binding;
91
91
  } catch (e) {
92
92
  loadErrors.push(e);
@@ -100,7 +100,7 @@ function requireNative() {
100
100
  try {
101
101
  const binding = require("@oxfmt/binding-win32-x64-msvc");
102
102
  const bindingPackageVersion = require("@oxfmt/binding-win32-x64-msvc/package.json").version;
103
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
103
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
104
104
  return binding;
105
105
  } catch (e) {
106
106
  loadErrors.push(e);
@@ -115,7 +115,7 @@ function requireNative() {
115
115
  try {
116
116
  const binding = require("@oxfmt/binding-win32-ia32-msvc");
117
117
  const bindingPackageVersion = require("@oxfmt/binding-win32-ia32-msvc/package.json").version;
118
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
118
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
119
119
  return binding;
120
120
  } catch (e) {
121
121
  loadErrors.push(e);
@@ -129,7 +129,7 @@ function requireNative() {
129
129
  try {
130
130
  const binding = require("@oxfmt/binding-win32-arm64-msvc");
131
131
  const bindingPackageVersion = require("@oxfmt/binding-win32-arm64-msvc/package.json").version;
132
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
132
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
133
133
  return binding;
134
134
  } catch (e) {
135
135
  loadErrors.push(e);
@@ -144,7 +144,7 @@ function requireNative() {
144
144
  try {
145
145
  const binding = require("@oxfmt/binding-darwin-universal");
146
146
  const bindingPackageVersion = require("@oxfmt/binding-darwin-universal/package.json").version;
147
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
147
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
148
148
  return binding;
149
149
  } catch (e) {
150
150
  loadErrors.push(e);
@@ -158,7 +158,7 @@ function requireNative() {
158
158
  try {
159
159
  const binding = require("@oxfmt/binding-darwin-x64");
160
160
  const bindingPackageVersion = require("@oxfmt/binding-darwin-x64/package.json").version;
161
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
161
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
162
162
  return binding;
163
163
  } catch (e) {
164
164
  loadErrors.push(e);
@@ -172,7 +172,7 @@ function requireNative() {
172
172
  try {
173
173
  const binding = require("@oxfmt/binding-darwin-arm64");
174
174
  const bindingPackageVersion = require("@oxfmt/binding-darwin-arm64/package.json").version;
175
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
175
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
176
176
  return binding;
177
177
  } catch (e) {
178
178
  loadErrors.push(e);
@@ -187,7 +187,7 @@ function requireNative() {
187
187
  try {
188
188
  const binding = require("@oxfmt/binding-freebsd-x64");
189
189
  const bindingPackageVersion = require("@oxfmt/binding-freebsd-x64/package.json").version;
190
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
190
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
191
191
  return binding;
192
192
  } catch (e) {
193
193
  loadErrors.push(e);
@@ -201,7 +201,7 @@ function requireNative() {
201
201
  try {
202
202
  const binding = require("@oxfmt/binding-freebsd-arm64");
203
203
  const bindingPackageVersion = require("@oxfmt/binding-freebsd-arm64/package.json").version;
204
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
204
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
205
205
  return binding;
206
206
  } catch (e) {
207
207
  loadErrors.push(e);
@@ -216,7 +216,7 @@ function requireNative() {
216
216
  try {
217
217
  const binding = require("@oxfmt/binding-linux-x64-musl");
218
218
  const bindingPackageVersion = require("@oxfmt/binding-linux-x64-musl/package.json").version;
219
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
219
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
220
220
  return binding;
221
221
  } catch (e) {
222
222
  loadErrors.push(e);
@@ -230,7 +230,7 @@ function requireNative() {
230
230
  try {
231
231
  const binding = require("@oxfmt/binding-linux-x64-gnu");
232
232
  const bindingPackageVersion = require("@oxfmt/binding-linux-x64-gnu/package.json").version;
233
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
233
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
234
234
  return binding;
235
235
  } catch (e) {
236
236
  loadErrors.push(e);
@@ -245,7 +245,7 @@ function requireNative() {
245
245
  try {
246
246
  const binding = require("@oxfmt/binding-linux-arm64-musl");
247
247
  const bindingPackageVersion = require("@oxfmt/binding-linux-arm64-musl/package.json").version;
248
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
248
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
249
249
  return binding;
250
250
  } catch (e) {
251
251
  loadErrors.push(e);
@@ -259,7 +259,7 @@ function requireNative() {
259
259
  try {
260
260
  const binding = require("@oxfmt/binding-linux-arm64-gnu");
261
261
  const bindingPackageVersion = require("@oxfmt/binding-linux-arm64-gnu/package.json").version;
262
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
262
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
263
263
  return binding;
264
264
  } catch (e) {
265
265
  loadErrors.push(e);
@@ -274,7 +274,7 @@ function requireNative() {
274
274
  try {
275
275
  const binding = require("@oxfmt/binding-linux-arm-musleabihf");
276
276
  const bindingPackageVersion = require("@oxfmt/binding-linux-arm-musleabihf/package.json").version;
277
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
277
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
278
278
  return binding;
279
279
  } catch (e) {
280
280
  loadErrors.push(e);
@@ -288,7 +288,7 @@ function requireNative() {
288
288
  try {
289
289
  const binding = require("@oxfmt/binding-linux-arm-gnueabihf");
290
290
  const bindingPackageVersion = require("@oxfmt/binding-linux-arm-gnueabihf/package.json").version;
291
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
291
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
292
292
  return binding;
293
293
  } catch (e) {
294
294
  loadErrors.push(e);
@@ -303,7 +303,7 @@ function requireNative() {
303
303
  try {
304
304
  const binding = require("@oxfmt/binding-linux-loong64-musl");
305
305
  const bindingPackageVersion = require("@oxfmt/binding-linux-loong64-musl/package.json").version;
306
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
306
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
307
307
  return binding;
308
308
  } catch (e) {
309
309
  loadErrors.push(e);
@@ -317,7 +317,7 @@ function requireNative() {
317
317
  try {
318
318
  const binding = require("@oxfmt/binding-linux-loong64-gnu");
319
319
  const bindingPackageVersion = require("@oxfmt/binding-linux-loong64-gnu/package.json").version;
320
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
320
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
321
321
  return binding;
322
322
  } catch (e) {
323
323
  loadErrors.push(e);
@@ -332,7 +332,7 @@ function requireNative() {
332
332
  try {
333
333
  const binding = require("@oxfmt/binding-linux-riscv64-musl");
334
334
  const bindingPackageVersion = require("@oxfmt/binding-linux-riscv64-musl/package.json").version;
335
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
335
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
336
336
  return binding;
337
337
  } catch (e) {
338
338
  loadErrors.push(e);
@@ -346,7 +346,7 @@ function requireNative() {
346
346
  try {
347
347
  const binding = require("@oxfmt/binding-linux-riscv64-gnu");
348
348
  const bindingPackageVersion = require("@oxfmt/binding-linux-riscv64-gnu/package.json").version;
349
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
349
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
350
350
  return binding;
351
351
  } catch (e) {
352
352
  loadErrors.push(e);
@@ -361,7 +361,7 @@ function requireNative() {
361
361
  try {
362
362
  const binding = require("@oxfmt/binding-linux-ppc64-gnu");
363
363
  const bindingPackageVersion = require("@oxfmt/binding-linux-ppc64-gnu/package.json").version;
364
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
364
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
365
365
  return binding;
366
366
  } catch (e) {
367
367
  loadErrors.push(e);
@@ -375,7 +375,7 @@ function requireNative() {
375
375
  try {
376
376
  const binding = require("@oxfmt/binding-linux-s390x-gnu");
377
377
  const bindingPackageVersion = require("@oxfmt/binding-linux-s390x-gnu/package.json").version;
378
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
378
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
379
379
  return binding;
380
380
  } catch (e) {
381
381
  loadErrors.push(e);
@@ -390,7 +390,7 @@ function requireNative() {
390
390
  try {
391
391
  const binding = require("@oxfmt/binding-openharmony-arm64");
392
392
  const bindingPackageVersion = require("@oxfmt/binding-openharmony-arm64/package.json").version;
393
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
393
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
394
394
  return binding;
395
395
  } catch (e) {
396
396
  loadErrors.push(e);
@@ -404,7 +404,7 @@ function requireNative() {
404
404
  try {
405
405
  const binding = require("@oxfmt/binding-openharmony-x64");
406
406
  const bindingPackageVersion = require("@oxfmt/binding-openharmony-x64/package.json").version;
407
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
407
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
408
408
  return binding;
409
409
  } catch (e) {
410
410
  loadErrors.push(e);
@@ -418,7 +418,7 @@ function requireNative() {
418
418
  try {
419
419
  const binding = require("@oxfmt/binding-openharmony-arm");
420
420
  const bindingPackageVersion = require("@oxfmt/binding-openharmony-arm/package.json").version;
421
- if (bindingPackageVersion !== "0.40.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.40.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
421
+ if (bindingPackageVersion !== "0.41.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.41.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
422
422
  return binding;
423
423
  } catch (e) {
424
424
  loadErrors.push(e);
@@ -1,2 +1,2 @@
1
- import { a as sortTailwindClasses, n as formatEmbeddedDoc, r as formatFile, t as formatEmbeddedCode } from "./apis-C4p62fZb.js";
1
+ import { a as sortTailwindClasses, n as formatEmbeddedDoc, r as formatFile, t as formatEmbeddedCode } from "./apis-CF7S9zfN.js";
2
2
  export { formatEmbeddedCode, formatEmbeddedDoc, formatFile, sortTailwindClasses };
package/dist/cli.js CHANGED
@@ -1,5 +1,5 @@
1
- import { r as runCli } from "./bindings-NtH60nWL.js";
2
- import { i as resolvePlugins } from "./apis-C4p62fZb.js";
1
+ import { r as runCli } from "./bindings-D6U4DxG3.js";
2
+ import { i as resolvePlugins } from "./apis-CF7S9zfN.js";
3
3
  import Tinypool from "tinypool";
4
4
  import { basename } from "node:path";
5
5
  import { pathToFileURL } from "node:url";
@@ -73,15 +73,15 @@ async function loadJsConfig(path) {
73
73
  const fileUrl = pathToFileURL(path);
74
74
  fileUrl.searchParams.set("cache", Date.now().toString());
75
75
  const { default: config } = await import(fileUrl.href);
76
- if (config === void 0) throw new Error(`Configuration file has no default export: ${path}`);
76
+ if (config === void 0) throw new Error("Configuration file has no default export.");
77
77
  if (basename(path) === VITE_CONFIG_NAME) {
78
78
  if (!isObject(config)) return null;
79
79
  const fmtConfig = config[VITE_OXFMT_CONFIG_FIELD];
80
80
  if (fmtConfig === void 0) return null;
81
- if (!isObject(fmtConfig)) throw new Error(`The \`${VITE_OXFMT_CONFIG_FIELD}\` field in the default export must be an object: ${path}`);
81
+ if (!isObject(fmtConfig)) throw new Error(`The \`${VITE_OXFMT_CONFIG_FIELD}\` field in the default export must be an object.`);
82
82
  return fmtConfig;
83
83
  }
84
- if (!isObject(config)) throw new Error(`Configuration file must have a default export that is an object: ${path}`);
84
+ if (!isObject(config)) throw new Error("Configuration file must have a default export that is an object.");
85
85
  return config;
86
86
  }
87
87
  //#endregion
@@ -90,6 +90,7 @@ async function loadJsConfig(path) {
90
90
  const args = process.argv.slice(2);
91
91
  if (!process.stdout.isTTY) process.stdout._handle?.setBlocking?.(true);
92
92
  if (!process.stdin.isTTY) process.stdin._handle?.setBlocking?.(true);
93
+ if (args.includes("--lsp")) process.stdout.write = process.stderr.write.bind(process.stderr);
93
94
  const [mode, exitCode] = await runCli(args, loadJsConfig, initExternalFormatter, formatFile, formatEmbeddedCode, formatEmbeddedDoc, sortTailwindClasses);
94
95
  if (mode === "init") {
95
96
  await import("./init-BbKOMZ57.js").then((m) => m.runInit());
package/dist/index.d.ts CHANGED
@@ -639,33 +639,38 @@ interface SortTailwindcssConfig {
639
639
  }
640
640
  //#endregion
641
641
  //#region src-js/index.d.ts
642
- /**
643
- * Define an oxfmt configuration with type inference.
644
- */
645
- declare function defineConfig<T extends Oxfmtrc>(config: T): T;
642
+ type OxfmtConfig = Oxfmtrc;
646
643
  /**
647
644
  * Configuration options for the `format()` API.
648
645
  *
649
646
  * Based on `FormatConfig` generated from the JSON Schema,
650
647
  * with additional deprecated aliases for backward compatibility.
648
+ * @deprecated Use `FormatConfig` instead.
651
649
  */
652
650
  type FormatOptions = FormatConfig & {
653
651
  /** @deprecated Use `sortImports` instead. */experimentalSortImports?: SortImportsConfig; /** @deprecated Use `sortPackageJson` instead. */
654
652
  experimentalSortPackageJson?: boolean | SortPackageJsonConfig; /** @deprecated Use `sortTailwindcss` instead. */
655
653
  experimentalTailwindcss?: SortTailwindcssConfig;
656
654
  };
655
+ /** @deprecated Use `FormatConfig["sortImports"]` instead. */
657
656
  type SortImportsOptions = SortImportsConfig;
657
+ /** @deprecated Use `FormatConfig["sortPackageJson"]` instead. */
658
658
  type SortPackageJsonOptions = SortPackageJsonConfig;
659
+ /** @deprecated Use `FormatConfig["sortTailwindcss"]` instead. */
659
660
  type SortTailwindcssOptions = SortTailwindcssConfig;
660
- /** @deprecated Use `SortTailwindcssOptions` instead. */
661
+ /** @deprecated Use `FormatConfig["sortTailwindcss"]` instead. */
661
662
  type TailwindcssOptions = SortTailwindcssConfig;
663
+ /**
664
+ * Define an oxfmt configuration with type inference.
665
+ */
666
+ declare function defineConfig<T extends OxfmtConfig>(config: T): T;
662
667
  /**
663
668
  * Format the given source text according to the specified options.
664
669
  */
665
- declare function format(fileName: string, sourceText: string, options?: FormatOptions): Promise<FormatResult>;
670
+ declare function format(fileName: string, sourceText: string, options?: FormatConfig): Promise<FormatResult>;
666
671
  /**
667
672
  * Format a JS/TS snippet for Prettier `textToDoc()` plugin flow.
668
673
  */
669
674
  declare function jsTextToDoc(sourceExt: string, sourceText: string, oxfmtPluginOptionsJson: string, parentContext: string): Promise<string | null>;
670
675
  //#endregion
671
- export { FormatOptions, SortImportsOptions, SortPackageJsonOptions, SortTailwindcssOptions, TailwindcssOptions, defineConfig, format, jsTextToDoc };
676
+ export { type FormatConfig, FormatOptions, OxfmtConfig, SortImportsOptions, SortPackageJsonOptions, SortTailwindcssOptions, TailwindcssOptions, defineConfig, format, jsTextToDoc };
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
- import { n as jsTextToDoc$1, t as format$1 } from "./bindings-NtH60nWL.js";
2
- import { a as sortTailwindClasses, i as resolvePlugins, n as formatEmbeddedDoc, r as formatFile, t as formatEmbeddedCode } from "./apis-C4p62fZb.js";
1
+ import { n as jsTextToDoc$1, t as format$1 } from "./bindings-D6U4DxG3.js";
2
+ import { a as sortTailwindClasses, i as resolvePlugins, n as formatEmbeddedDoc, r as formatFile, t as formatEmbeddedCode } from "./apis-CF7S9zfN.js";
3
3
  //#region src-js/index.ts
4
4
  /**
5
5
  * Define an oxfmt configuration with type inference.
@@ -1,5 +1,5 @@
1
- import "./bindings-NtH60nWL.js";
2
- import "./apis-C4p62fZb.js";
1
+ import "./bindings-D6U4DxG3.js";
2
+ import "./apis-CF7S9zfN.js";
3
3
  import { jsTextToDoc } from "./index.js";
4
4
  //#region src-js/libs/prettier-plugin-oxfmt/text-to-doc.ts
5
5
  const textToDoc = async (embeddedSourceText, textToDocOptions) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "oxfmt",
3
- "version": "0.40.0",
3
+ "version": "0.41.0",
4
4
  "description": "Formatter for the JavaScript Oxidation Compiler",
5
5
  "keywords": [
6
6
  "formatter",
@@ -67,24 +67,24 @@
67
67
  },
68
68
  "preferUnplugged": true,
69
69
  "optionalDependencies": {
70
- "@oxfmt/binding-darwin-arm64": "0.40.0",
71
- "@oxfmt/binding-android-arm64": "0.40.0",
72
- "@oxfmt/binding-win32-arm64-msvc": "0.40.0",
73
- "@oxfmt/binding-linux-arm64-gnu": "0.40.0",
74
- "@oxfmt/binding-linux-arm64-musl": "0.40.0",
75
- "@oxfmt/binding-openharmony-arm64": "0.40.0",
76
- "@oxfmt/binding-android-arm-eabi": "0.40.0",
77
- "@oxfmt/binding-linux-arm-gnueabihf": "0.40.0",
78
- "@oxfmt/binding-linux-arm-musleabihf": "0.40.0",
79
- "@oxfmt/binding-win32-ia32-msvc": "0.40.0",
80
- "@oxfmt/binding-linux-ppc64-gnu": "0.40.0",
81
- "@oxfmt/binding-linux-riscv64-gnu": "0.40.0",
82
- "@oxfmt/binding-linux-riscv64-musl": "0.40.0",
83
- "@oxfmt/binding-linux-s390x-gnu": "0.40.0",
84
- "@oxfmt/binding-darwin-x64": "0.40.0",
85
- "@oxfmt/binding-win32-x64-msvc": "0.40.0",
86
- "@oxfmt/binding-freebsd-x64": "0.40.0",
87
- "@oxfmt/binding-linux-x64-gnu": "0.40.0",
88
- "@oxfmt/binding-linux-x64-musl": "0.40.0"
70
+ "@oxfmt/binding-darwin-arm64": "0.41.0",
71
+ "@oxfmt/binding-android-arm64": "0.41.0",
72
+ "@oxfmt/binding-win32-arm64-msvc": "0.41.0",
73
+ "@oxfmt/binding-linux-arm64-gnu": "0.41.0",
74
+ "@oxfmt/binding-linux-arm64-musl": "0.41.0",
75
+ "@oxfmt/binding-openharmony-arm64": "0.41.0",
76
+ "@oxfmt/binding-android-arm-eabi": "0.41.0",
77
+ "@oxfmt/binding-linux-arm-gnueabihf": "0.41.0",
78
+ "@oxfmt/binding-linux-arm-musleabihf": "0.41.0",
79
+ "@oxfmt/binding-win32-ia32-msvc": "0.41.0",
80
+ "@oxfmt/binding-linux-ppc64-gnu": "0.41.0",
81
+ "@oxfmt/binding-linux-riscv64-gnu": "0.41.0",
82
+ "@oxfmt/binding-linux-riscv64-musl": "0.41.0",
83
+ "@oxfmt/binding-linux-s390x-gnu": "0.41.0",
84
+ "@oxfmt/binding-darwin-x64": "0.41.0",
85
+ "@oxfmt/binding-win32-x64-msvc": "0.41.0",
86
+ "@oxfmt/binding-freebsd-x64": "0.41.0",
87
+ "@oxfmt/binding-linux-x64-gnu": "0.41.0",
88
+ "@oxfmt/binding-linux-x64-musl": "0.41.0"
89
89
  }
90
90
  }