@bytecodealliance/jco 1.15.4 → 1.16.1

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": "@bytecodealliance/jco",
3
- "version": "1.15.4",
3
+ "version": "1.16.1",
4
4
  "description": "JavaScript tooling for working with WebAssembly Components",
5
5
  "homepage": "https://github.com/bytecodealliance/jco#readme",
6
6
  "author": "Guy Bedford",
@@ -63,6 +63,7 @@
63
63
  "build": "cargo xtask build debug",
64
64
  "build:release": "cargo xtask build release",
65
65
  "build:types:preview2-shim": "npm run build:types:preview2-shim --include-workspace-root",
66
+ "build:test:components": "cargo xtask build-test-components",
66
67
  "fmt": "npm run lint:fix",
67
68
  "lint": "eslint -c ../../eslint.config.mjs --ext .js src test",
68
69
  "lint:fix": "npm run lint -- --fix",
@@ -179,6 +179,11 @@ export async function transpileComponent(component, opts = {}) {
179
179
  'async exports cannot be specified in sync mode (consider adding --async-mode=jspi)'
180
180
  );
181
181
  }
182
+ if (asyncMode === 'sync' && asyncImports.size > 0) {
183
+ throw new Error(
184
+ 'async imports cannot be specified in sync mode (consider adding --async-mode=jspi)'
185
+ );
186
+ }
182
187
  let asyncModeObj;
183
188
  if (asyncMode === 'sync') {
184
189
  asyncModeObj = null;
package/src/jco.js CHANGED
@@ -25,7 +25,7 @@ program
25
25
  )
26
26
  .usage('<command> [options]')
27
27
  .enablePositionalOptions()
28
- .version('1.15.4');
28
+ .version('1.16.1');
29
29
 
30
30
  function myParseInt(value) {
31
31
  return parseInt(value, 10);