Skip to content

Commit 060c02e

Browse files
fix(examples): reduce required improts for ts-resource-import
1 parent c92add3 commit 060c02e

File tree

2 files changed

+1
-7
lines changed

2 files changed

+1
-7
lines changed

examples/components/ts-resource-import/embedding.mts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,6 @@ async function main() {
4343
'test:component/resources': {
4444
Example: LocalExample,
4545
},
46-
'wasi:http/types': {},
47-
'wasi:http/outgoing-handler': {
48-
handle: () => {
49-
throw new Error('NOT SUPPORTED');
50-
},
51-
},
5246
};
5347

5448
// Instantiate the component with the custom imports

examples/components/ts-resource-import/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"scripts": {
66
"gen:types": "jco guest-types -o generated/types/guest/import wit/ --world-name imported",
77
"build:ts": "rollup -c component.rollup.mjs",
8-
"build:component": "jco componentize -w wit/ --world-name imported dist/component.js -o dist/component.wasm",
8+
"build:component": "jco componentize -w wit/ --world-name imported --disable=http dist/component.js -o dist/component.wasm",
99
"build": "npm run gen:types && npm run build:ts && npm run build:component",
1010
"transpile": "jco transpile dist/component.wasm -o dist/transpiled --instantiation=async",
1111
"run:embedding": "node dist/transpiled/embedding.js",

0 commit comments

Comments
 (0)