Skip to content

Commit f4f9663

Browse files
committed
fix: address CRCs
1 parent 36826e3 commit f4f9663

File tree

4 files changed

+13
-5
lines changed

4 files changed

+13
-5
lines changed

packages/jentic-openapi-validator-speclynx/src/jentic/apitools/openapi/validator/backends/speclynx/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,9 @@ def __init__(
6060
When specified, custom plugins are merged with the built-in plugins (both are loaded).
6161
If None (default), only the built-in plugins directory is used (which is empty by default).
6262
Plugins must export a function that receives a toolbox object with:
63-
- deps: External dependencies (vscode-languageserver-types, @speclynx/apidom-reference)
63+
- deps: External dependencies including vscode-languageserver-types, @speclynx/apidom-core,
64+
@speclynx/apidom-datamodel, @speclynx/apidom-json-path, @speclynx/apidom-json-pointer,
65+
@speclynx/apidom-traverse, and @speclynx/apidom-reference
6466
- diagnostics: Array to collect validation diagnostics
6567
See resources/plugins/example-plugin.mjs.sample for plugin format.
6668
"""

packages/jentic-openapi-validator-speclynx/src/jentic/apitools/openapi/validator/backends/speclynx/resources/plugins/example-plugin.mjs.sample

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,12 @@
77
* Plugin structure:
88
* - Must export a default function that accepts a toolbox object with:
99
* - diagnostics: Array to collect validation diagnostics
10-
* - deps: External dependencies (vscode-languageserver-types, @speclynx/apidom-reference)
10+
* - deps: External dependencies (vscode-languageserver-types, @speclynx/apidom-core, etc.)
1111
* - Returns an object with pre/post hooks and a visitor property
1212
* - The visitor contains methods named after ApiDOM element types
13-
* - Each visitor method receives the element being visited
13+
* - Each visitor method receives a path object with information about the current element
14+
* - path.node: The actual ApiDOM element being visited
15+
* - path.getPathKeys(): Returns the JSON path to the element
1416
*
1517
* @param {Object} toolbox - Plugin toolbox
1618
* @param {Array} toolbox.diagnostics - Array to collect validation diagnostics

packages/jentic-openapi-validator-speclynx/src/jentic/apitools/openapi/validator/backends/speclynx/resources/plugins/openapi-document.mjs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,9 @@
88
* When traversing parseResult.api (valid documents), ParseResultElement is not visited.
99
*
1010
* Plugin receives toolbox with:
11-
* - deps: External dependencies (vscode-languageserver-types, @speclynx/apidom-reference)
11+
* - deps: External dependencies including vscode-languageserver-types, @speclynx/apidom-core,
12+
* @speclynx/apidom-datamodel, @speclynx/apidom-json-path, @speclynx/apidom-json-pointer,
13+
* @speclynx/apidom-traverse, and @speclynx/apidom-reference
1214
* - diagnostics: Array to collect validation diagnostics
1315
*/
1416

packages/jentic-openapi-validator-speclynx/tests/fixtures/plugins/version-validator.mjs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22
* Test plugin that validates info.version is a string
33
*
44
* Plugin receives toolbox with:
5-
* - deps: External dependencies (vscode-languageserver-types, @speclynx/apidom-reference)
5+
* - deps: External dependencies including vscode-languageserver-types, @speclynx/apidom-core,
6+
* @speclynx/apidom-datamodel, @speclynx/apidom-json-path, @speclynx/apidom-json-pointer,
7+
* @speclynx/apidom-traverse, and @speclynx/apidom-reference
68
* - diagnostics: Array to collect validation diagnostics
79
*/
810

0 commit comments

Comments
 (0)