oxfmt 0.49.0 → 0.51.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.
Files changed (33) hide show
  1. package/configuration_schema.json +2 -2
  2. package/dist/{apis-By1xj7IP.js → apis-H4bwlBNm.js} +6 -17
  3. package/dist/{bindings-Cdg_nxGV.js → bindings-qpSSlUMn.js} +26 -26
  4. package/dist/cli-worker.js +1 -1
  5. package/dist/cli.js +48 -29
  6. package/dist/{dist-Bbs0xV9H.js → dist-DieWQ1D0.js} +12 -15
  7. package/dist/index.d.ts +1 -1
  8. package/dist/index.js +4 -4
  9. package/dist/{jiti-Bb1dT6Cw-DezGRPD7.js → jiti-Bb1dT6Cw-BtDs_aWX.js} +2 -2
  10. package/dist/{migrate-prettier-Bze9N_6F.js → migrate-prettier-CBzqnxHw.js} +1 -1
  11. package/dist/{plugin-CwlqDRt_.js → plugin-DiRKvkOT.js} +70 -26
  12. package/dist/{prettier-s1WPCGVk.js → prettier-D7Ly-aG0.js} +13 -13
  13. package/dist/{prettier-plugin-oxfmt-BjdgYnLg.js → prettier-plugin-oxfmt-Besh6ER1.js} +37 -3
  14. package/dist/{resolve-pWjAK-4f-BnquIxPb.js → sorter-BZkvDMjt-r7M4pM9t.js} +325 -4
  15. package/dist/{sorter-l2HyESZg.js → sorter-D0Nd4qpi.js} +1 -2
  16. package/dist/{v3-D-mr2VVh-Bw8A9MXh.js → v3-D-mr2VVh-DBBWnwM8.js} +3 -4
  17. package/dist/{v4-C-HWEQJm-B81QD_Ac.js → v4-C-HWEQJm-OZwT-Lc8.js} +3 -4
  18. package/package.json +20 -20
  19. package/dist/chunk-DSjvVL_1-B3jw0SMn.js +0 -36
  20. package/dist/sorter-BZkvDMjt-y2u_e1ZW.js +0 -212
  21. package/dist/utils-D8dQkKEd-Dgy5UIHl.js +0 -81
  22. /package/dist/{acorn-ay2Aj6GQ.js → acorn-Cz3eAoi8.js} +0 -0
  23. /package/dist/{angular-z1ZEe5V_.js → angular-BzDc3wVg.js} +0 -0
  24. /package/dist/{estree-DZBnPYMx.js → estree-BL2Xy2uB.js} +0 -0
  25. /package/dist/{flow-ChhAFZSt.js → flow-Bj4lBR-Y.js} +0 -0
  26. /package/dist/{glimmer-Cg8KQipT.js → glimmer-C2ccnwyy.js} +0 -0
  27. /package/dist/{graphql-DsP-ifm0.js → graphql-D73FSqwO.js} +0 -0
  28. /package/dist/{html-7pWx9LND.js → html-ENhiK7MR.js} +0 -0
  29. /package/dist/{markdown-CCrs3bBt.js → markdown-CDTH7TpJ.js} +0 -0
  30. /package/dist/{meriyah-TC7VDz8E.js → meriyah-C-N-xeFc.js} +0 -0
  31. /package/dist/{postcss-ZbUej7DN.js → postcss-CS83Slco.js} +0 -0
  32. /package/dist/{typescript-Cgpjcksz.js → typescript-DkgFgfZO.js} +0 -0
  33. /package/dist/{yaml-DLZBHI7f.js → yaml-Ddi9JTUZ.js} +0 -0
@@ -645,12 +645,12 @@
645
645
  "markdownDescription": "Specifies whether sorting should be case-sensitive.\n\n- Default: `true`"
646
646
  },
647
647
  "internalPattern": {
648
- "description": "Specifies a prefix for identifying internal imports.\n\nThis is useful for distinguishing your own modules from external dependencies.\n\n- Default: `[\"~/\", \"@/\"]`",
648
+ "description": "Specifies a prefix for identifying internal imports.\n\nThis is useful for distinguishing your own modules from external dependencies.\n\n- Default: `[\"~/\", \"@/\", \"#\"]`",
649
649
  "type": "array",
650
650
  "items": {
651
651
  "type": "string"
652
652
  },
653
- "markdownDescription": "Specifies a prefix for identifying internal imports.\n\nThis is useful for distinguishing your own modules from external dependencies.\n\n- Default: `[\"~/\", \"@/\"]`"
653
+ "markdownDescription": "Specifies a prefix for identifying internal imports.\n\nThis is useful for distinguishing your own modules from external dependencies.\n\n- Default: `[\"~/\", \"@/\", \"#\"]`"
654
654
  },
655
655
  "newlinesBetween": {
656
656
  "description": "Specifies whether to add newlines between groups.\n\nWhen `false`, no newlines are added between groups.\n\n- Default: `true`",
@@ -13,7 +13,7 @@ async function loadCached(key, loader) {
13
13
  }
14
14
  async function loadPrettier() {
15
15
  return loadCached("prettier", async () => {
16
- const prettier = await import("./prettier-s1WPCGVk.js");
16
+ const prettier = await import("./prettier-D7Ly-aG0.js");
17
17
  const { formatOptionsHiddenDefaults } = prettier.__internal;
18
18
  formatOptionsHiddenDefaults.parentParser = null;
19
19
  formatOptionsHiddenDefaults.__onHtmlRoot = null;
@@ -22,17 +22,6 @@ async function loadPrettier() {
22
22
  });
23
23
  }
24
24
  /**
25
- * TODO: Plugins support
26
- * - Read `plugins` field
27
- * - Load plugins dynamically and parse `languages` field
28
- * - Map file extensions and filenames to Prettier parsers
29
- *
30
- * @returns Array of loaded plugin's `languages` info
31
- */
32
- async function resolvePlugins() {
33
- return [];
34
- }
35
- /**
36
25
  * Format non-js file
37
26
  *
38
27
  * @returns Formatted code
@@ -95,7 +84,7 @@ async function formatEmbeddedDoc({ texts, options }) {
95
84
  * Option mapping (sortTailwindcss.xxx → tailwindXxx) is also done in Rust side.
96
85
  */
97
86
  async function setupTailwindPlugin(options) {
98
- CACHES.tailwindPlugin ??= await loadCached("tailwindPlugin", () => import("./dist-Bbs0xV9H.js"));
87
+ CACHES.tailwindPlugin ??= await loadCached("tailwindPlugin", () => import("./dist-DieWQ1D0.js"));
99
88
  options.plugins ??= [];
100
89
  options.plugins.push(CACHES.tailwindPlugin);
101
90
  }
@@ -105,7 +94,7 @@ async function setupTailwindPlugin(options) {
105
94
  * @returns Array of sorted class strings (same order/length as input)
106
95
  */
107
96
  async function sortTailwindClasses({ classes, options }) {
108
- CACHES.tailwindSorter ??= await loadCached("tailwindSorter", () => import("./sorter-l2HyESZg.js"));
97
+ CACHES.tailwindSorter ??= await loadCached("tailwindSorter", () => import("./sorter-D0Nd4qpi.js"));
109
98
  const { createSorter } = CACHES.tailwindSorter;
110
99
  return (await createSorter({
111
100
  filepath: options.filepath,
@@ -119,7 +108,7 @@ async function sortTailwindClasses({ classes, options }) {
119
108
  * Load prettier-plugin-svelte to provide the `svelte` parser.
120
109
  */
121
110
  async function setupSveltePlugin(options) {
122
- CACHES.sveltePlugin ??= await loadCached("sveltePlugin", async () => await import("./plugin-CwlqDRt_.js").then((m) => /* @__PURE__ */ __toESM(m.default, 1)));
111
+ CACHES.sveltePlugin ??= await loadCached("sveltePlugin", async () => await import("./plugin-DiRKvkOT.js").then((m) => /* @__PURE__ */ __toESM(m.default, 1)));
123
112
  options.plugins ??= [];
124
113
  options.plugins.push(CACHES.sveltePlugin);
125
114
  }
@@ -127,9 +116,9 @@ async function setupSveltePlugin(options) {
127
116
  * Load oxfmt plugin for js-in-xxx parsers.
128
117
  */
129
118
  async function setupOxfmtPlugin(options) {
130
- CACHES.oxfmtPlugin ??= await loadCached("oxfmtPlugin", async () => await import("./prettier-plugin-oxfmt-BjdgYnLg.js"));
119
+ CACHES.oxfmtPlugin ??= await loadCached("oxfmtPlugin", async () => await import("./prettier-plugin-oxfmt-Besh6ER1.js"));
131
120
  options.plugins ??= [];
132
121
  options.plugins.push(CACHES.oxfmtPlugin);
133
122
  }
134
123
  //#endregion
135
- export { sortTailwindClasses as a, resolvePlugins as i, formatEmbeddedDoc as n, formatFile as r, formatEmbeddedCode as t };
124
+ export { sortTailwindClasses as i, formatEmbeddedDoc as n, formatFile as r, formatEmbeddedCode as t };
@@ -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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
60
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
74
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
89
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
103
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
118
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
132
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
147
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
161
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
175
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
190
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
204
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
219
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
233
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
248
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
262
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
277
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
291
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
306
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
320
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
335
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
349
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
364
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
378
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
393
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
407
+ if (bindingPackageVersion !== "0.51.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.51.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.49.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.49.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
421
+ if (bindingPackageVersion !== "0.51.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.51.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-By1xj7IP.js";
1
+ import { i as sortTailwindClasses, n as formatEmbeddedDoc, r as formatFile, t as formatEmbeddedCode } from "./apis-H4bwlBNm.js";
2
2
  export { formatEmbeddedCode, formatEmbeddedDoc, formatFile, sortTailwindClasses };
package/dist/cli.js CHANGED
@@ -1,5 +1,4 @@
1
- import { r as runCli } from "./bindings-Cdg_nxGV.js";
2
- import { i as resolvePlugins } from "./apis-By1xj7IP.js";
1
+ import { r as runCli } from "./bindings-qpSSlUMn.js";
3
2
  import Tinypool from "tinypool";
4
3
  import { fileURLToPath, pathToFileURL } from "node:url";
5
4
  import { extname } from "node:path";
@@ -13,7 +12,6 @@ async function initExternalFormatter(numThreads) {
13
12
  runtime: "child_process",
14
13
  env: process.env
15
14
  });
16
- return resolvePlugins();
17
15
  }
18
16
  async function disposeExternalFormatter() {
19
17
  await pool?.destroy();
@@ -53,21 +51,13 @@ async function sortTailwindClasses(options, classes) {
53
51
  }, { name: "sortTailwindClasses" }).catch(() => null);
54
52
  }
55
53
  //#endregion
56
- //#region src-js/cli/js_config/node_version.ts
57
- const NODE_TYPESCRIPT_SUPPORT_RANGE = "^20.19.0 || >=22.12.0";
54
+ //#region ../shared/src-js/node_version.ts
55
+ const NODE_TYPESCRIPT_SUPPORT_RANGE = "^20.19.0 || >=22.18.0";
58
56
  const TS_MODULE_EXTENSIONS = new Set([
59
57
  ".ts",
60
58
  ".mts",
61
59
  ".cts"
62
60
  ]);
63
- function getUnsupportedTypeScriptModuleLoadHint(err, specifier, nodeVersion = process.version) {
64
- if (!isTypeScriptModuleSpecifier(specifier) || !isUnknownFileExtensionError(err)) return null;
65
- return `TypeScript config files require Node.js ${NODE_TYPESCRIPT_SUPPORT_RANGE}.\nDetected Node.js ${nodeVersion}.\nPlease upgrade Node.js or use a JSON config file instead.`;
66
- }
67
- function isTypeScriptModuleSpecifier(specifier) {
68
- const ext = extname(normalizeModuleSpecifierPath(specifier)).toLowerCase();
69
- return TS_MODULE_EXTENSIONS.has(ext);
70
- }
71
61
  function normalizeModuleSpecifierPath(specifier) {
72
62
  if (!specifier.startsWith("file:")) return specifier;
73
63
  try {
@@ -76,31 +66,60 @@ function normalizeModuleSpecifierPath(specifier) {
76
66
  return specifier;
77
67
  }
78
68
  }
69
+ function isTypeScriptModuleSpecifier(specifier) {
70
+ const ext = extname(normalizeModuleSpecifierPath(specifier)).toLowerCase();
71
+ return TS_MODULE_EXTENSIONS.has(ext);
72
+ }
79
73
  function isUnknownFileExtensionError(err) {
80
74
  if (err?.code === "ERR_UNKNOWN_FILE_EXTENSION") return true;
81
75
  const message = err?.message;
82
76
  return typeof message === "string" && /unknown(?: or unsupported)? file extension/i.test(message);
83
77
  }
78
+ function getErrorMessage(err) {
79
+ if (err instanceof Error) return err.message;
80
+ return String(err);
81
+ }
82
+ /**
83
+ * Returns a complete replacement string suitable for `Error.message` assignment
84
+ * (includes the original error message + appended hint), or `null` when the
85
+ * error is unrelated to TS module loading. Callers should overwrite, not append.
86
+ */
87
+ function getUnsupportedTypeScriptModuleLoadHintForError(err, specifier, nodeVersion = process.version) {
88
+ if (!isTypeScriptModuleSpecifier(specifier) || !isUnknownFileExtensionError(err)) return null;
89
+ return `${getErrorMessage(err)}\n\nTypeScript config files require Node.js ${NODE_TYPESCRIPT_SUPPORT_RANGE}.\nDetected Node.js ${nodeVersion}.\nPlease upgrade Node.js or use a JSON config file instead.`;
90
+ }
84
91
  //#endregion
85
- //#region src-js/cli/js_config/index.ts
86
- const isObject = (v) => typeof v === "object" && v !== null && !Array.isArray(v);
92
+ //#region ../shared/src-js/js_config.ts
87
93
  /**
88
- * Load a JavaScript/TypeScript config file and import it.
94
+ * Import a JS/TS config file and return its `default` export.
95
+ *
96
+ * - Bypasses Node.js module cache (uses `?cache=<key>`) so changed files reload (used for LSP).
97
+ * - On `ERR_UNKNOWN_FILE_EXTENSION` for TS specifiers, overwrites `err.message` with a
98
+ * Node.js upgrade hint that already includes the original message.
89
99
  *
90
- * Uses native Node.js `import()` to evaluate the config file.
91
- * The config file should have a default export containing the oxfmt configuration object.
100
+ * @param path - Absolute path to the JS/TS config file
101
+ * @param cacheKey - Cache-busting key.
102
+ * Callers decide whether to use a fresh value per call or share one across a batch.
103
+ * @throws When the file has no `default` export,
104
+ * or import fails (with rewritten message for unsupported TS module load).
92
105
  */
93
- async function importJsConfig(path) {
106
+ async function importJsConfig(path, cacheKey) {
94
107
  const fileUrl = pathToFileURL(path);
95
- fileUrl.searchParams.set("cache", Date.now().toString());
96
- const { default: config } = await import(fileUrl.href).catch((err) => {
97
- const hint = getUnsupportedTypeScriptModuleLoadHint(err, path);
98
- if (hint && err instanceof Error) err.message += `\n\n${hint}`;
108
+ fileUrl.searchParams.set("cache", cacheKey.toString());
109
+ let module;
110
+ try {
111
+ module = await import(fileUrl.href);
112
+ } catch (err) {
113
+ const hint = getUnsupportedTypeScriptModuleLoadHintForError(err, path);
114
+ if (hint && err instanceof Error) err.message = hint;
99
115
  throw err;
100
- });
101
- if (config === void 0) throw new Error("Configuration file has no default export.");
102
- return config;
116
+ }
117
+ if (module.default === void 0) throw new Error("Configuration file has no default export.");
118
+ return module.default;
103
119
  }
120
+ //#endregion
121
+ //#region src-js/cli/js_config.ts
122
+ const isObject = (v) => typeof v === "object" && v !== null && !Array.isArray(v);
104
123
  /**
105
124
  * Load and validate a standard oxfmt JS/TS config file.
106
125
  * The default export must be a plain object containing oxfmt options.
@@ -109,7 +128,7 @@ async function importJsConfig(path) {
109
128
  * @returns Config object
110
129
  */
111
130
  async function loadJsConfig(path) {
112
- const config = await importJsConfig(path);
131
+ const config = await importJsConfig(path, Date.now());
113
132
  if (!isObject(config)) throw new Error("Configuration file must have a default export that is an object.");
114
133
  return config;
115
134
  }
@@ -121,7 +140,7 @@ const VITE_OXFMT_CONFIG_FIELD = "fmt";
121
140
  * @returns Config object from `.fmt` field, or `null` to signal "skip"
122
141
  */
123
142
  async function loadVitePlusConfig(path) {
124
- const config = await importJsConfig(path);
143
+ const config = await importJsConfig(path, Date.now());
125
144
  if (!isObject(config)) return null;
126
145
  const fmtConfig = config[VITE_OXFMT_CONFIG_FIELD];
127
146
  if (fmtConfig === void 0) return null;
@@ -141,7 +160,7 @@ async function loadVitePlusConfig(path) {
141
160
  return;
142
161
  }
143
162
  if (mode === "migrate:prettier") {
144
- await import("./migrate-prettier-Bze9N_6F.js").then((m) => m.runMigratePrettier());
163
+ await import("./migrate-prettier-CBzqnxHw.js").then((m) => m.runMigratePrettier());
145
164
  return;
146
165
  }
147
166
  if (mode === "migrate:biome") {
@@ -1,15 +1,12 @@
1
1
  import { o as __toESM } from "./chunk-HkwdBwDg.js";
2
2
  import { n as init_babel, parsers as ra, t as babel_exports } from "./babel-Cs312VeV.js";
3
- import index_exports, { t as init_prettier } from "./prettier-s1WPCGVk.js";
4
- import { a as __toESM$1, t as __commonJSMin } from "./chunk-DSjvVL_1-B3jw0SMn.js";
5
- import { n as loadIfExists, r as maybeResolve, t as expiringMap } from "./resolve-pWjAK-4f-BnquIxPb.js";
6
- import { i as visit, n as cacheForDirs, r as spliceChangesIntoString } from "./utils-D8dQkKEd-Dgy5UIHl.js";
7
- import { a as sortClasses, i as sortClassList, n as error, o as warn, r as getTailwindConfig$1 } from "./sorter-BZkvDMjt-y2u_e1ZW.js";
8
- import { parsers as fn, t as init_angular } from "./angular-z1ZEe5V_.js";
9
- import { n as postcss_exports, parsers as en, t as init_postcss } from "./postcss-ZbUej7DN.js";
3
+ import index_exports, { t as init_prettier } from "./prettier-D7Ly-aG0.js";
4
+ import { a as sortClasses, b as __toESM$1, c as cacheForDirs, d as expiringMap, f as loadIfExists, g as __commonJSMin, i as sortClassList, l as spliceChangesIntoString, n as error, o as warn, p as maybeResolve, r as getTailwindConfig$1, u as visit } from "./sorter-BZkvDMjt-r7M4pM9t.js";
5
+ import { parsers as fn, t as init_angular } from "./angular-BzDc3wVg.js";
6
+ import { n as postcss_exports, parsers as en, t as init_postcss } from "./postcss-CS83Slco.js";
10
7
  import * as path from "node:path";
11
8
  import { isAbsolute } from "path";
12
- //#region ../../node_modules/.pnpm/prettier-plugin-tailwindcss@0.0.0-insiders.3997fbd_prettier-plugin-svelte@3.5.1_prettie_57f1f908c644a91a29f5821c3681dd20/node_modules/prettier-plugin-tailwindcss/dist/index.mjs
9
+ //#region ../../node_modules/.pnpm/prettier-plugin-tailwindcss@0.0.0-insiders.3997fbd_prettier-plugin-svelte@3.5.2_prettie_a08864e9b63fbbe60e61e20100abcb82/node_modules/prettier-plugin-tailwindcss/dist/index.mjs
13
10
  init_angular();
14
11
  init_babel();
15
12
  init_postcss();
@@ -1052,7 +1049,7 @@ const { parsers, printers } = createPlugin([
1052
1049
  staticAttrs: ["class"],
1053
1050
  load: [{
1054
1051
  name: "prettier/plugins/html",
1055
- importer: () => import("./html-7pWx9LND.js")
1052
+ importer: () => import("./html-ENhiK7MR.js")
1056
1053
  }],
1057
1054
  compatible: ["prettier-plugin-organize-attributes"],
1058
1055
  parsers: {
@@ -1067,7 +1064,7 @@ const { parsers, printers } = createPlugin([
1067
1064
  staticAttrs: ["class"],
1068
1065
  load: [{
1069
1066
  name: "prettier/plugins/glimmer",
1070
- importer: () => import("./glimmer-Cg8KQipT.js")
1067
+ importer: () => import("./glimmer-C2ccnwyy.js")
1071
1068
  }],
1072
1069
  parsers: { glimmer: {} },
1073
1070
  transform: transformGlimmer
@@ -1099,19 +1096,19 @@ const { parsers, printers } = createPlugin([
1099
1096
  __js_expression: { load: [babel_exports] },
1100
1097
  typescript: { load: [{
1101
1098
  name: "prettier/plugins/typescript",
1102
- importer: () => import("./typescript-Cgpjcksz.js")
1099
+ importer: () => import("./typescript-DkgFgfZO.js")
1103
1100
  }] },
1104
1101
  meriyah: { load: [{
1105
1102
  name: "prettier/plugins/meriyah",
1106
- importer: () => import("./meriyah-TC7VDz8E.js")
1103
+ importer: () => import("./meriyah-C-N-xeFc.js")
1107
1104
  }] },
1108
1105
  acorn: { load: [{
1109
1106
  name: "prettier/plugins/acorn",
1110
- importer: () => import("./acorn-ay2Aj6GQ.js")
1107
+ importer: () => import("./acorn-Cz3eAoi8.js")
1111
1108
  }] },
1112
1109
  flow: { load: [{
1113
1110
  name: "prettier/plugins/flow",
1114
- importer: () => import("./flow-ChhAFZSt.js")
1111
+ importer: () => import("./flow-Bj4lBR-Y.js")
1115
1112
  }] },
1116
1113
  oxc: { load: [{
1117
1114
  name: "@prettier/plugin-oxc",
@@ -1142,7 +1139,7 @@ const { parsers, printers } = createPlugin([
1142
1139
  staticAttrs: ["class"],
1143
1140
  load: [{
1144
1141
  name: "prettier-plugin-svelte",
1145
- importer: () => import("./plugin-CwlqDRt_.js").then((m) => /* @__PURE__ */ __toESM(m.default, 1))
1142
+ importer: () => import("./plugin-DiRKvkOT.js").then((m) => /* @__PURE__ */ __toESM(m.default, 1))
1146
1143
  }],
1147
1144
  parsers: { svelte: {} },
1148
1145
  printers: { "svelte-ast": {} },
package/dist/index.d.ts CHANGED
@@ -635,7 +635,7 @@ interface SortImportsConfig {
635
635
  *
636
636
  * This is useful for distinguishing your own modules from external dependencies.
637
637
  *
638
- * - Default: `["~/", "@/"]`
638
+ * - Default: `["~/", "@/", "#"]`
639
639
  */
640
640
  internalPattern?: string[];
641
641
  /**
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
- import { n as jsTextToDoc$1, t as format$1 } from "./bindings-Cdg_nxGV.js";
2
- import { a as sortTailwindClasses, i as resolvePlugins, n as formatEmbeddedDoc, r as formatFile, t as formatEmbeddedCode } from "./apis-By1xj7IP.js";
1
+ import { n as jsTextToDoc$1, t as format$1 } from "./bindings-qpSSlUMn.js";
2
+ import { i as sortTailwindClasses, n as formatEmbeddedDoc, r as formatFile, t as formatEmbeddedCode } from "./apis-H4bwlBNm.js";
3
3
  //#region src-js/index.ts
4
4
  /**
5
5
  * Define an oxfmt configuration with type inference.
@@ -13,7 +13,7 @@ function defineConfig(config) {
13
13
  async function format(fileName, sourceText, options) {
14
14
  if (typeof fileName !== "string") throw new TypeError("`fileName` must be a string");
15
15
  if (typeof sourceText !== "string") throw new TypeError("`sourceText` must be a string");
16
- return format$1(fileName, sourceText, options ?? {}, resolvePlugins, (options, code) => formatFile({
16
+ return format$1(fileName, sourceText, options ?? {}, (options, code) => formatFile({
17
17
  options,
18
18
  code
19
19
  }), (options, code) => formatEmbeddedCode({
@@ -31,7 +31,7 @@ async function format(fileName, sourceText, options) {
31
31
  * Format a JS/TS snippet for Prettier `textToDoc()` plugin flow.
32
32
  */
33
33
  async function jsTextToDoc(sourceExt, sourceText, oxfmtPluginOptionsJson, parentContext) {
34
- return jsTextToDoc$1(sourceExt, sourceText, oxfmtPluginOptionsJson, parentContext, resolvePlugins, (_options, _code) => Promise.reject(), (options, code) => formatEmbeddedCode({
34
+ return jsTextToDoc$1(sourceExt, sourceText, oxfmtPluginOptionsJson, parentContext, (_options, _code) => Promise.reject(), (options, code) => formatEmbeddedCode({
35
35
  options,
36
36
  code
37
37
  }), (options, texts) => formatEmbeddedDoc({
@@ -1,6 +1,6 @@
1
- import { a as __toESM, i as __require, t as __commonJSMin } from "./chunk-DSjvVL_1-B3jw0SMn.js";
1
+ import { b as __toESM, g as __commonJSMin, y as __require } from "./sorter-BZkvDMjt-r7M4pM9t.js";
2
2
  import { createRequire } from "node:module";
3
- //#region ../../node_modules/.pnpm/prettier-plugin-tailwindcss@0.0.0-insiders.3997fbd_prettier-plugin-svelte@3.5.1_prettie_57f1f908c644a91a29f5821c3681dd20/node_modules/prettier-plugin-tailwindcss/dist/jiti-Bb1dT6Cw.mjs
3
+ //#region ../../node_modules/.pnpm/prettier-plugin-tailwindcss@0.0.0-insiders.3997fbd_prettier-plugin-svelte@3.5.2_prettie_a08864e9b63fbbe60e61e20100abcb82/node_modules/prettier-plugin-tailwindcss/dist/jiti-Bb1dT6Cw.mjs
4
4
  var require_jiti = /* @__PURE__ */ __commonJSMin(((exports, module) => {
5
5
  (() => {
6
6
  var e = { "./node_modules/.pnpm/mlly@1.8.0/node_modules/mlly/dist lazy recursive": function(e) {
@@ -9,7 +9,7 @@ import { readFile } from "node:fs/promises";
9
9
  async function runMigratePrettier() {
10
10
  const cwd = process.cwd();
11
11
  if (await hasOxfmtrcFile(cwd)) return exitWithError("Oxfmt configuration file already exists.");
12
- const { resolveConfigFile, resolveConfig } = await import("./prettier-s1WPCGVk.js");
12
+ const { resolveConfigFile, resolveConfig } = await import("./prettier-D7Ly-aG0.js");
13
13
  const prettierConfigPath = await resolveConfigFile(join(cwd, "dummy.js"));
14
14
  if (!prettierConfigPath) {
15
15
  console.log("No Prettier configuration file found.");