Files
marqdo/public/stdlib/table.mq.md
T
cflmyandCursor 25b7be6739 Add usable table/map stdlib with put, and show run bindings in view.
Authors can update nested collections via table.put/表.改 instead of json.set chains; view’s right rail adds collapsible Variables from the entry env.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-12 11:49:48 +08:00

26 lines
477 B
Markdown

---
title: lib/table — collections
description: put, append, and map helpers
> lib/table.mq.md
---
# main
Prefer `table.put` for element updates (`at=` text key, **1-based** int, or list path). Use `json` for parse/stringify only.
*`h` = > table.put in=None at=Authorization value=Bearer-demo*
`xs` =
| v |
|---|
| a |
| b |
*`xs` = > table.put in=`xs` at=1 value=A*
*`n` = > table.rows xs=`xs`*
> print text=`h`[^Authorization]
> print text=`xs`[^1]
> print text=`n`