componentized/directory

componentized:component

interface dev

WASM components for creating and interacting with WASM components.

interface types componentized:component/types@0.1.1-dev since 0.1.0

Types shared by the interfaces in this package.

Types

record malformedsince 0.1.0

A malformed input.

  • name: option<string>

    Calls accepting multiple inputs name the one that is malformed.

  • message: string

    Why the input is invalid.

variant error-codesince 0.1.0

An error from a call.

  • malformed: malformed

    A value cannot be parsed to its expected type.

  • not-component: option<string>

    A wasm that must be a component is not, e.g. a core module. Calls accepting multiple wasms name the one that is not a component.

  • not-found: option<string>

    The item does not exist, optionally naming it, e.g. a path, URL, reference or package.

  • other: option<string>

    Any other error, with an optional message.

type wasmsince 0.1.0

The bytes of a WebAssembly binary, a component unless stated otherwise.

  • list<u8>

WIT

/// Types shared by the interfaces in this package.
@since(version = 0.1.0)
interface types {
  /// A `malformed` input.
  @since(version = 0.1.0)
  record malformed {
    /// Calls accepting multiple inputs name the one that is malformed.
    name: option<string>,
    /// Why the input is invalid.
    message: string,
  }

  /// An error from a call.
  @since(version = 0.1.0)
  variant error-code {
    /// A value cannot be parsed to its expected type.
    malformed(malformed),
    /// A wasm that must be a component is not, e.g. a core module. Calls accepting multiple
    /// wasms name the one that is not a component.
    not-component(option<string>),
    /// The item does not exist, optionally naming it, e.g. a path, URL, reference or package.
    not-found(option<string>),
    /// Any other error, with an optional message.
    other(option<string>),
  }

  /// The bytes of a WebAssembly binary, a component unless stated otherwise.
  @since(version = 0.1.0)
  type wasm = list<u8>;
}