Frontmatter imports are now valid YAML (`import:` / `导入:` with bind→target entries), removing spaced keys. Add `marqdo migrate imports`, hard-error the old one-liner form, and migrate lib/ext/examples/tests/docs accordingly. Co-authored-by: Cursor <cursoragent@cursor.com>
943 B
943 B
markup, title, description, import
| markup | title | description | import | ||||||
|---|---|---|---|---|---|---|---|---|---|
| occlusion | ext/net/websocket | WebSocket client Resource (ADR 0007). |
|
_load
p = > plugin.native_path name="web"
p
plugin.load path=
p
print text=ext/net: native web plugin not found sys.exit code=1
ws
+ `timeout_sec`=30
WebSocket client helper.
_load
out=
| timeout_sec | _type |
|---|---|
timeout_sec |
ws |
out
connect
+ `url`
+ `message`=""
+ `headers`=None
Single request–response: connect to url, send message, collect up to 256 server text replies (each up to 1 MiB), close. Transport errors and timeouts return {ok:false, error} instead of looking like an empty successful reply.
timeout = timeout_sec)
> web_ws_connect url=url message=message headers=headers timeout_sec=timeout