Skip to content

Commit

Permalink
fix: specify that parse function input can be also an object (#312)
Browse files Browse the repository at this point in the history
* fix: test added for object type input

* error fixed

* all tests passed

* semicolon added

* final changes made
  • Loading branch information
vishesh13byte authored Jun 4, 2021
1 parent bc7980f commit 7bd675c
Show file tree
Hide file tree
Showing 5 changed files with 344 additions and 194 deletions.
2 changes: 1 addition & 1 deletion dist/bundle.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion lib/parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ module.exports = {
/**
* Parses and validate an AsyncAPI document from YAML or JSON.
*
* @param {String} asyncapiYAMLorJSON An AsyncAPI document in JSON or YAML format.
* @param {(String | Object)} asyncapiYAMLorJSON An AsyncAPI document in JSON or YAML format.
* @param {Object} [options] Configuration options.
* @param {String} [options.path] Path to the AsyncAPI document. It will be used to resolve relative references. Defaults to current working dir.
* @param {Object} [options.parse] Options object to pass to {@link https://apidevtools.org/json-schema-ref-parser/docs/options.html|json-schema-ref-parser}.
Expand Down
Loading

0 comments on commit 7bd675c

Please sign in to comment.