JSBlock JS 代码块
结构声明
- TS Declaration
- Java Class
- JSON Schema
interface JSBlock {
"concept": "JSBlock", // 产品概念
"label": string, // JS 代码块标题
"code": string, // 代码内容
}
class JSBlockTreeNode {
ConceptEnum concept; // 产品概念
String label; // JS 代码块标题
String code; // 代码内容
}
{
"$schema": "http://json-schema.org/draft-07/schema#",
"$ref": "#/definitions/JSBlock",
"definitions": {
"JSBlock": {
"type": "object",
"properties": {
"concept": {
"type": "string",
"const": "JSBlock"
},
"label": {
"type": "string"
},
"code": {
"type": "string"
}
},
"required": [
"concept",
"label",
"code"
],
"additionalProperties": false
}
}
}
示例
简单示例
- JSON
- YAML
{
"concept": "JSBlock",
"label": "JS 代码块",
"code": null
}
concept: JSBlock
label: JS 代码块
code: null