Generates the source files for a WebAssembly target from a Rust project.
steps:
- uses: giancosta86/aurora-github/actions/generate-wasm-target@v7
with:
target: web
npm-scope: npmuser
development: true
target-directory: pkg
project-directory: .
This action invokes wasm-pack - with arguments depending on the inputs - to generate a WebAssembly project from the given Rust sources.
- The
wasm-pack
command must be available in the system - for example, via install-wasm-pack.
Name | Type | Description | Default value |
---|---|---|---|
target |
string | The target of the wasm-pack build command |
|
npm-scope |
string | The package scope or <ROOT> , for npm targets |
|
development |
boolean | Enable debugging info | |
target-directory |
string | Directory (relative to project-directory ) for the generated target |
|
project-directory |
string | The directory containing Cargo.toml |
. |