feat(tsl-codegen): add decoupled documentation toolkit

Generate TSL API Markdown from YAML or JSON into a configurable project scope.\nAdd file and directory lint modes, tags-aware indexing, and keyword search across tags and descriptions.\nBundle the toolkit through the playbook build and sync workflows.
This commit is contained in:
csh
2026-07-20 09:08:38 +08:00
parent 1d5304e7b6
commit c69278283f
18 changed files with 13955 additions and 12821 deletions
+39
View File
@@ -0,0 +1,39 @@
module: 示例 / 数组
path: base/example
functions:
- signature: demoNow()
desc: 返回示例值。
returns: integer
example: |
return demoNow();
// 输出:1
- signature: demoFn(src, mode, factor, ...)
tags: [示例, 数组]
desc: 按指定模式处理数组并返回结果。
params:
- name: src
type: array
desc: 待处理数组
- name: mode
type: integer
desc: 处理模式,取值见下。
values:
- value: 0
desc: 原样返回
- value: 1
desc: 去重
- name: factor
type: float
optional: true
desc: 默认 1.0,结果乘以该系数。
- name: "..."
type: nil|array
optional: true
desc: 需要追加处理的其他数组。
returns: array
example: |
src := array(1, 1, 2);
return demoFn(src, 1, 2.0);
// 输出:array(2,4)