componentized/directory

componentized:config-overlay

component

Combines value from two wasi:config/stores into a single store. The 'store' import is the base set of values, while the 'overlay' import, a mirror of the store interface, contributes additional values overriding in the case of a conflict.

Imports

Exports

WIT

package root:component;

world root {
  import wasi:config/store@0.2.0-draft;
  import overlay: interface {
    variant error {
      upstream(string),
      io(string),
    }

    get: func(key: string) -> result<option<string>, error>;

    get-all: func() -> result<list<tuple<string, string>>, error>;
  }

  export wasi:config/store@0.2.0-draft;
}
package wasi:config@0.2.0-draft {
  interface store {
    variant error {
      upstream(string),
      io(string),
    }

    get: func(key: string) -> result<option<string>, error>;

    get-all: func() -> result<list<tuple<string, string>>, error>;
  }
}