Skip to content

wasm: Add example with two modules #3154

Open
@codefromthecrypt

Description

@codefromthecrypt

We need another example where one module exports a function another module imports (both compiled by TinyGo with -target=wasm). Making the example here has the advantage of being testable. That said, the current site content doesn't make it easy to discover which examples exist. There may be some work on that side to improve discovery.

Note that a PR to affect the site is not in this repo (https://github.com/tinygo-org/tinygo-site/blob/release/content/docs/guides/webassembly.md)


We have recently a bit more discovery in wasm examples recently. Notably, you can see a list of sorts of examples. However, it isn't on the release branch, yet, so not navigable from the website guide.

minor note that a guide should include a end to end example of a module exporting a function, another module importing it, and then executing the resulting modules. something along this line.

Originally posted by @james-lawrence in #3147 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsDocumentation needed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions