Skip to content

Commit 0591e9e

Browse files
committed
fix: Spelling errors and expanded detail
1 parent 9272a7b commit 0591e9e

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

rfcs/2024-05-19-on-demand-isolated-component.md

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,9 @@ console.log(pythonComponent.hello());
4646
console.log(javascriptComponent.hello());
4747
```
4848

49-
In the example above, the action of importing each module invokes Wasm component compilation / transpilation and Wasm instantiation behind the scenes, producing "on-demand" isolated Wasm Components with high-level, comprehensively-typed JavaScript interfaces. The interface exported by the on-demand module can be invoked, re-exported and/or incorporated idiomatically into other JavaScript modules.
49+
In the example above, the action of importing each module invokes Wasm Component compilation / transpilation and Wasm instantiation behind the scenes, producing "on-demand" isolated components with high-level, comprehensively-typed JavaScript interfaces. The interface exported by the on-demand module can be invoked, re-exported and/or incorporated idiomatically into other JavaScript modules.
5050

51-
Although the example uses [dynamic import][dynamic-import], the import specifiers in use should work equally well when used with static imports.
51+
Although the example uses [dynamic import][dynamic-import], the import specifiers should work equally well when used with static imports.
5252

5353
### Goals
5454

@@ -62,7 +62,7 @@ _As an app developer, when I tell an LLM to generate a chunk of code in my (or t
6262

6363
### Non-goals
6464

65-
- Define an explicit mechanism to provide a pre-defined, custom "standard library" to components (this will be the subject of a future RFC)
65+
- Implement a mechanism to provide a pre-defined, custom "standard library" to components (this will be the subject of a future RFC)
6666
- Prescribe specific userspace APIs or capabilities that will be available to components
6767
- Establish a security boundary for managing the execution of untrusted code
6868
- Integrate a scheme for policy enforcement on data passed into and out of components
@@ -75,9 +75,15 @@ _As an app developer, when I tell an LLM to generate a chunk of code in my (or t
7575

7676
[Web Assembly (Wasm)][wasm] presents a tantelizing substrate for browser-based isolated components. In 2024, it is possible to run programs written in many languages (C, Rust, JavaScript, Java and Python to name just a few) within the Wasm runtime that is available in all major web browsers. Furthermore, [Wasm Components][wasm-components] provide a common IDL ([WIT][wit]) and ABI for connecting Wasm originating from different language toolchains. [The Bytecode Alliance][bytecode-alliance] hosts a number of tools that enable polyfill-like workflows while Wasm Components are still nascent.
7777

78+
#### Core Wasm and Wasm Components
79+
80+
Wasm runtimes in web browsers all implement [Core Wasm], which may be thought of as the minimum viable API for Wasm to be a useful construct.
81+
82+
[Wasm Components][wasm-components] constitute an ABI defined on top of [Core Wasm], as part of ongoing [WASI] development efforts. Native support for Wasm Components is available in some Wasm runtimes, but it is not as ubiquitous as [Core Wasm].
83+
7884
### Components
7985

80-
Although the term "component" is commonly used to refer to discrete, composable units of a user interface, this document uses the term in the sense of a [Wasm Component][wasm-components]. In this sense, a component may be thought of as any re-usable chunk of software.
86+
Although the term "component" commonly refers to discrete, composable units of a user interface, this document uses the term in the sense of a [Wasm Component][wasm-components]. In this sense, a component may be thought of as any re-usable chunk of software.
8187

8288
For the purposes of reasoning about what may or may not be part of a component's interface: anything that can be expressed in a [WIT][wit] definition is considered a candidate (this means you can express anything you want, probably).
8389

@@ -203,3 +209,5 @@ Yes. Each instance of the JS VM equals about 8MB of Wasm. There are strategies w
203209
[cargo-component]: https://github.com/bytecodealliance/cargo-component
204210
[Service Worker]: https://developer.mozilla.org/en-US/docs/Web/API/Service_Worker_API
205211
[js-component-bindgen-transpile]: https://docs.rs/js-component-bindgen/latest/js_component_bindgen/fn.transpile.html
212+
[Core Wasm]: https://www.w3.org/TR/wasm-core-1/
213+
[WASI]: https://wasi.dev/

0 commit comments

Comments
 (0)