express-openapi-validator
express-openapi-validator copied to clipboard
Feature request: split apiSpec into several YAML-files
Is your feature request related to a problem? Please describe.
I have many routes grouped by some resources and I can't neither split YAML-file nor use a merged JS configuration object for apiSpec option
Describe the solution you'd like It would be great to indicate a main and secondary YAML-files where I'll be able to store routes divided by resources.
Describe alternatives you've considered
I tried to indicate external YAML-files on the root level of the main YAML-file using $ref with no luck.
I tried to convert several YAML-files into JS objects and merge their paths props but unluckily when I try to use this merged object all external $refs stopped working because they are searched in a root directory (a root directory of the project in my case if it is set by CWD setting in VS Code).
I tried to merge several YAML-files into JS-object and convert it back to YAML-file in a temp directory but that way I will also need to copy all external reference YAML-files to temp directory as well keeping subdirectory structure for all referenced YAMl-files.