With this release, we're embracing WASM even further.
Core migration to WASM
Now that WASM plugin support is up and running, we've hit a non-ideal situation where we have multiple competing implementations for "tools" in proto. We currently have 3 different approaches:
- Tools implemented in Rust and built into proto's core.
- TOML based plugins, with a simple Rust based wrapper.
- WASM based plugins.
This is far too many implementations to support, and makes it extremely difficult to add new features for tools, as it affects all 3. To remedy this situation, we've decided to migrate all core tools to WASM plugins, and remove the Rust based implementations. The core of proto and its CLI will still be Rust, but will be slowly migrated into a truly pluggable architecture.
To test drive and experiment with this solution, we've migrated Bun, Deno, and Go into WASM plugins, and starting with this release, they are purely powered by WASM and have been removed entirely from the Rust implementation.
In the next release, we hope to migrate Node.js and Rust as well. And in a future release, the TOML
plugins will be compiled into
and loaded as WASM plugins. From here, we will have a single tool implementation, and can implement
some really exciting features!
github: plugin configuration
source: configuration strategy, plugins can now be configured with the
strategy to locate WASM files from GitHub releases. For example, the
bun_plugin.wasm file will be
downloaded from our
bun-plugin's latest release.
bun = "github:moonrepo/bun-plugin"
Bun support is built into proto, there is merely an example!
proto plugins commands
With the advent of plugins, we thought it would be nice to know which plugins are actually
configured and in use, without having to manually search config files across the file system, and as
such, have added a new
proto plugins command.
This command is simple. It will list all plugins that are currently configured for the current
project, by loading all
.prototools files up the tree, and loading the user
$ proto plugins
bun - Bun
deno - Deno
go - Go
View the official release for a full list of changes.
- Added documentation for writing unit tests for WASM plugins.
proto useto load and merge all
.prototoolsfrom the current directory and upwards.
- Many WASM API improvements.