ajv-validator / ajv-validator/ajv-errors

support $ref

未關閉
#18 0 則留言 9 個 reaction 已指派 0 人 在 GitHub 檢視
主要語言
TypeScript
星號
289
分支
21
PR 合併指標
30 天內沒有已合併 PR

描述

I would love to see support added for the ```$ref``` keyword. I have several error messages that are used throughout my schemas, and it would be helpful to only have to define them once.

```js
// error schema
{
"$id": "errors",
"string": "must be a string",
"basicObject": {
"type": { "$ref": "#/string" }
}
}

// schema
{
"type": "string",
"errorMessage": { "$ref": "errors#/basicObject" }
}
```

貢獻指南

這個儲存庫沒有索引到貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。