@next/swc-wasm-nodejs 16.0.2 → 16.1.0-canary.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@next/swc-wasm-nodejs",
3
- "version": "16.0.2",
3
+ "version": "16.1.0-canary.0",
4
4
  "files": [
5
5
  "wasm_bg.wasm",
6
6
  "wasm.js",
package/wasm.d.ts CHANGED
@@ -1,11 +1,11 @@
1
1
  /* tslint:disable */
2
2
  /* eslint-disable */
3
3
  export function expandNextJsTemplate(content: Uint8Array, template_path: string, next_package_dir_path: string, replacements: any, injections: any, imports: any): string;
4
- export function minifySync(s: string, opts: any): any;
4
+ export function transform(s: any, opts: any): Promise<any>;
5
+ export function transformSync(s: any, opts: any): any;
5
6
  export function parseSync(s: string, opts: any): any;
6
7
  export function minify(s: string, opts: any): Promise<any>;
7
- export function transform(s: any, opts: any): Promise<any>;
8
+ export function minifySync(s: string, opts: any): any;
8
9
  export function parse(s: string, opts: any): Promise<any>;
9
- export function transformSync(s: any, opts: any): any;
10
10
  export function mdxCompileSync(value: string, opts: any): any;
11
11
  export function mdxCompile(value: string, opts: any): Promise<any>;
package/wasm.js CHANGED
@@ -255,12 +255,22 @@ module.exports.expandNextJsTemplate = function(content, template_path, next_pack
255
255
  };
256
256
 
257
257
  /**
258
- * @param {string} s
258
+ * @param {any} s
259
+ * @param {any} opts
260
+ * @returns {Promise<any>}
261
+ */
262
+ module.exports.transform = function(s, opts) {
263
+ const ret = wasm.transform(s, opts);
264
+ return ret;
265
+ };
266
+
267
+ /**
268
+ * @param {any} s
259
269
  * @param {any} opts
260
270
  * @returns {any}
261
271
  */
262
- module.exports.minifySync = function(s, opts) {
263
- const ret = wasm.minifySync(s, opts);
272
+ module.exports.transformSync = function(s, opts) {
273
+ const ret = wasm.transformSync(s, opts);
264
274
  if (ret[2]) {
265
275
  throw takeFromExternrefTable0(ret[1]);
266
276
  }
@@ -291,13 +301,16 @@ module.exports.minify = function(s, opts) {
291
301
  };
292
302
 
293
303
  /**
294
- * @param {any} s
304
+ * @param {string} s
295
305
  * @param {any} opts
296
- * @returns {Promise<any>}
306
+ * @returns {any}
297
307
  */
298
- module.exports.transform = function(s, opts) {
299
- const ret = wasm.transform(s, opts);
300
- return ret;
308
+ module.exports.minifySync = function(s, opts) {
309
+ const ret = wasm.minifySync(s, opts);
310
+ if (ret[2]) {
311
+ throw takeFromExternrefTable0(ret[1]);
312
+ }
313
+ return takeFromExternrefTable0(ret[0]);
301
314
  };
302
315
 
303
316
  /**
@@ -310,19 +323,6 @@ module.exports.parse = function(s, opts) {
310
323
  return ret;
311
324
  };
312
325
 
313
- /**
314
- * @param {any} s
315
- * @param {any} opts
316
- * @returns {any}
317
- */
318
- module.exports.transformSync = function(s, opts) {
319
- const ret = wasm.transformSync(s, opts);
320
- if (ret[2]) {
321
- throw takeFromExternrefTable0(ret[1]);
322
- }
323
- return takeFromExternrefTable0(ret[0]);
324
- };
325
-
326
326
  /**
327
327
  * @param {string} value
328
328
  * @param {any} opts
@@ -347,11 +347,11 @@ module.exports.mdxCompile = function(value, opts) {
347
347
  };
348
348
 
349
349
  function __wbg_adapter_50(arg0, arg1, arg2) {
350
- wasm.closure1166_externref_shim(arg0, arg1, arg2);
350
+ wasm.closure1165_externref_shim(arg0, arg1, arg2);
351
351
  }
352
352
 
353
353
  function __wbg_adapter_79(arg0, arg1, arg2, arg3) {
354
- wasm.closure124_externref_shim(arg0, arg1, arg2, arg3);
354
+ wasm.closure126_externref_shim(arg0, arg1, arg2, arg3);
355
355
  }
356
356
 
357
357
  module.exports.__wbg_String_fed4d24b68977888 = function(arg0, arg1) {
@@ -534,13 +534,13 @@ module.exports.__wbg_next_6574e1a8a62d1055 = function() { return handleError(fun
534
534
  return ret;
535
535
  }, arguments) };
536
536
 
537
- module.exports.__wbg_queueMicrotask_6c22d88054515cb4 = function(arg0) {
538
- const ret = arg0.queueMicrotask;
539
- return ret;
537
+ module.exports.__wbg_queueMicrotask_97d92b4fcc8a61c5 = function(arg0) {
538
+ queueMicrotask(arg0);
540
539
  };
541
540
 
542
- module.exports.__wbg_queueMicrotask_b81e3a75ab81ca62 = function(arg0) {
543
- queueMicrotask(arg0);
541
+ module.exports.__wbg_queueMicrotask_d3219def82552485 = function(arg0) {
542
+ const ret = arg0.queueMicrotask;
543
+ return ret;
544
544
  };
545
545
 
546
546
  module.exports.__wbg_resolve_4851785c9c5f573d = function(arg0) {
@@ -631,8 +631,8 @@ module.exports.__wbindgen_cb_drop = function(arg0) {
631
631
  return ret;
632
632
  };
633
633
 
634
- module.exports.__wbindgen_closure_wrapper23882 = function(arg0, arg1, arg2) {
635
- const ret = makeMutClosure(arg0, arg1, 1167, __wbg_adapter_50);
634
+ module.exports.__wbindgen_closure_wrapper23640 = function(arg0, arg1, arg2) {
635
+ const ret = makeMutClosure(arg0, arg1, 1166, __wbg_adapter_50);
636
636
  return ret;
637
637
  };
638
638
 
package/wasm_bg.wasm CHANGED
Binary file