-
Notifications
You must be signed in to change notification settings - Fork 447
Open
Description
💡 Feature description
When generating Deno bindings (maybe all bindings?), it would be great if the generated JS file included a @ts-self-types
comment. This would let Deno tooling access type definitions automatically.
💻 Basic example
Instead of myproject.js
starting with:
function addToExternrefTable0(obj) {
const idx = wasm.__externref_table_alloc();
wasm.__wbindgen_export_2.set(idx, obj);
return idx;
}
It would start with:
// @ts-self-types="./myproject.d.ts"
function addToExternrefTable0(obj) {
const idx = wasm.__externref_table_alloc();
wasm.__wbindgen_export_2.set(idx, obj);
return idx;
}
Metadata
Metadata
Assignees
Labels
No labels