Closed nao50 closed 4 years ago
You're using filter
wrong, and only asking json-refs
to resolve invalid
, relative
and remote
references, but there are none. Maybe filter
is improperly named but that is the list of references types to resolve. filter
is documented here: https://github.com/whitlockjc/json-refs/blob/master/docs/API.md#module_json-refs.JsonRefsOptions
Closing this as it's not a json-refs
bug. Feel free to communicate here and we can reopen if we find a bug.
Hi, thank you for the wonderful library. I have one question.
My environment
node: 12.6.0 json-refs: 3.0.15
Problems
I tried to convert the following
root.yaml
file to a yaml file with followingindex.ts
that resolves $ref. However, I can't solve the problem the way I want.root.yaml
index.ts
Expected Output
Actual Output
If I create another file like the following
ref.yaml
and pass it to the above typescript likefs.readFileSync("ref.yaml")
, I got the expected behavior.ref.yaml
Actual Output
If possible, I would like to use only
root.yaml
to solve the problem. Is there a shortage or mistake in my JsonRefsOptions specification?Thanks.