@next/swc-wasm-nodejs 16.1.0-canary.14 → 16.1.0-canary.16

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.1.0-canary.14",
3
+ "version": "16.1.0-canary.16",
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
- export function mdxCompile(value: string, opts: any): Promise<any>;
4
3
  export function mdxCompileSync(value: string, opts: any): any;
4
+ export function mdxCompile(value: string, opts: any): Promise<any>;
5
+ export function parse(s: string, opts: any): Promise<any>;
6
+ export function minify(s: string, opts: any): Promise<any>;
5
7
  export function expandNextJsTemplate(content: Uint8Array, template_path: string, next_package_dir_path: string, replacements: any, injections: any, imports: any): string;
8
+ export function transform(s: any, opts: any): Promise<any>;
6
9
  export function minifySync(s: string, opts: any): any;
7
10
  export function transformSync(s: any, opts: any): any;
8
- export function transform(s: any, opts: any): Promise<any>;
9
- export function parse(s: string, opts: any): Promise<any>;
10
11
  export function parseSync(s: string, opts: any): any;
11
- export function minify(s: string, opts: any): Promise<any>;
package/wasm.js CHANGED
@@ -216,15 +216,6 @@ function debugString(val) {
216
216
  // TODO we could test for more things here, like `Set`s and `Map`s.
217
217
  return className;
218
218
  }
219
- /**
220
- * @param {string} value
221
- * @param {any} opts
222
- * @returns {Promise<any>}
223
- */
224
- module.exports.mdxCompile = function(value, opts) {
225
- const ret = wasm.mdxCompile(value, opts);
226
- return ret;
227
- };
228
219
 
229
220
  function takeFromExternrefTable0(idx) {
230
221
  const value = wasm.__wbindgen_export_4.get(idx);
@@ -244,6 +235,36 @@ module.exports.mdxCompileSync = function(value, opts) {
244
235
  return takeFromExternrefTable0(ret[0]);
245
236
  };
246
237
 
238
+ /**
239
+ * @param {string} value
240
+ * @param {any} opts
241
+ * @returns {Promise<any>}
242
+ */
243
+ module.exports.mdxCompile = function(value, opts) {
244
+ const ret = wasm.mdxCompile(value, opts);
245
+ return ret;
246
+ };
247
+
248
+ /**
249
+ * @param {string} s
250
+ * @param {any} opts
251
+ * @returns {Promise<any>}
252
+ */
253
+ module.exports.parse = function(s, opts) {
254
+ const ret = wasm.parse(s, opts);
255
+ return ret;
256
+ };
257
+
258
+ /**
259
+ * @param {string} s
260
+ * @param {any} opts
261
+ * @returns {Promise<any>}
262
+ */
263
+ module.exports.minify = function(s, opts) {
264
+ const ret = wasm.minify(s, opts);
265
+ return ret;
266
+ };
267
+
247
268
  function passArray8ToWasm0(arg, malloc) {
248
269
  const ptr = malloc(arg.length * 1, 1) >>> 0;
249
270
  getUint8ArrayMemory0().set(arg, ptr / 1);
@@ -275,6 +296,16 @@ module.exports.expandNextJsTemplate = function(content, template_path, next_pack
275
296
  return v4;
276
297
  };
277
298
 
299
+ /**
300
+ * @param {any} s
301
+ * @param {any} opts
302
+ * @returns {Promise<any>}
303
+ */
304
+ module.exports.transform = function(s, opts) {
305
+ const ret = wasm.transform(s, opts);
306
+ return ret;
307
+ };
308
+
278
309
  /**
279
310
  * @param {string} s
280
311
  * @param {any} opts
@@ -301,26 +332,6 @@ module.exports.transformSync = function(s, opts) {
301
332
  return takeFromExternrefTable0(ret[0]);
302
333
  };
303
334
 
304
- /**
305
- * @param {any} s
306
- * @param {any} opts
307
- * @returns {Promise<any>}
308
- */
309
- module.exports.transform = function(s, opts) {
310
- const ret = wasm.transform(s, opts);
311
- return ret;
312
- };
313
-
314
- /**
315
- * @param {string} s
316
- * @param {any} opts
317
- * @returns {Promise<any>}
318
- */
319
- module.exports.parse = function(s, opts) {
320
- const ret = wasm.parse(s, opts);
321
- return ret;
322
- };
323
-
324
335
  /**
325
336
  * @param {string} s
326
337
  * @param {any} opts
@@ -334,16 +345,6 @@ module.exports.parseSync = function(s, opts) {
334
345
  return takeFromExternrefTable0(ret[0]);
335
346
  };
336
347
 
337
- /**
338
- * @param {string} s
339
- * @param {any} opts
340
- * @returns {Promise<any>}
341
- */
342
- module.exports.minify = function(s, opts) {
343
- const ret = wasm.minify(s, opts);
344
- return ret;
345
- };
346
-
347
348
  function __wbg_adapter_50(arg0, arg1, arg2) {
348
349
  wasm.closure1159_externref_shim(arg0, arg1, arg2);
349
350
  }
@@ -629,7 +630,7 @@ module.exports.__wbindgen_cb_drop = function(arg0) {
629
630
  return ret;
630
631
  };
631
632
 
632
- module.exports.__wbindgen_closure_wrapper23601 = function(arg0, arg1, arg2) {
633
+ module.exports.__wbindgen_closure_wrapper23586 = function(arg0, arg1, arg2) {
633
634
  const ret = makeMutClosure(arg0, arg1, 1160, __wbg_adapter_50);
634
635
  return ret;
635
636
  };
package/wasm_bg.wasm CHANGED
Binary file