w3c / wot-scripting-api

Web of Things (WoT) Scripting API
http://w3c.github.io/wot-scripting-api/
Other
42 stars 28 forks source link

We should clarify the document scope in the Introduction section #476

Open lu-zero opened 1 year ago

lu-zero commented 1 year ago
zolkis commented 1 year ago

In the early times of the WoT WG, there was formal objection against the Scripting API becoming a normative web spec. In addition, browser makers were reluctant to the idea of implementing a rather open-ended API in the browser, with all the open-ended dependencies (for the varieties of IoT protocols supported).

Instead, the following approach was recommended: use the HTTP binding for the web browsers, which already is supported by existing web APIs.

Also, since Scripting API is an optional element in the WoT Architecture, it is left to the applications how do they implement the WoT network API specified in the WoT specs.

However, the Scripting API spec is a good informative document on how in general to implement WoT. The prose is based on web/infra specs, i.e. specifies what is needed for a native browser implementation. This needs to be translated in the case of other types of implementations.

The main WG reference implementation, node-wot (TypeScript) is not a native browser implementation. So that is already a translation of the Scripting API spec to another implementation.

Since there are no native browser implementations at the moment, also there is no direct test framework that can be integrated to wpt (Web Platform Tests). It can only be indirectly validated via node-wot implementation feedback, and from other implementations.

So I do agree this situation needs to be explained in the introduction (with links).

JKRhb commented 11 months ago

I think this issue should be resolvable relatively quickly, right? I added the Spec-improvement label to sort of label it as a TODO item – feel free to change that if another label should be more appropriate here :)