Skip to content

Commit

Permalink
Merge pull request wasmerio#364 from wasmerio/dts-for-WasmerSDKBundled
Browse files Browse the repository at this point in the history
Make sure users still get typings whenever they import a file from `dist/`
  • Loading branch information
syrusakbary authored Dec 14, 2023
2 parents 4340567 + b7ecb2c commit b4bb602
Show file tree
Hide file tree
Showing 8 changed files with 18 additions and 1,068 deletions.
5 changes: 0 additions & 5 deletions .babelrc

This file was deleted.

File renamed without changes.
10 changes: 4 additions & 6 deletions lib_bundled.ts → WasmerSDKBundled.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
export * from "./lib";
// @ts-ignore
import { init as load, InitInput, InitOutput, ThreadPoolWorker } from "./lib";
export * from "./WasmerSDK";
import { init as load, InitInput, InitOutput } from "./WasmerSDK";
// @ts-ignore
import wasm_bytes from "./pkg/wasmer_js_bg.wasm";


/**
* Initialize the underlying WebAssembly module.
* Initialize the underlying WebAssembly module, defaulting to an embedded
* copy of the `*.wasm` file.
*/

export const init = async (module_or_path?: InitInput | Promise<InitInput>, maybe_memory?: WebAssembly.Memory): Promise<InitOutput> => {
if (!module_or_path) {
// @ts-ignore
Expand Down
2 changes: 1 addition & 1 deletion docs/typedoc.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"entryPoints": [
"../lib.ts"
"../WasmerSDK.ts"
],
"out": "public",
"$schema": "https://typedoc.org/schema.json"
Expand Down
Loading

0 comments on commit b4bb602

Please sign in to comment.