When building the API console from a local RAML file it is now trying to download the RAML file from the build location. But there's no file to download.
Option 1:
It should copy the file to the build location. In this case the CLI tool has to accept argument to copy dependency files as well but the user would need to provide them all when using the command.
Option 2:
It should automatically set --use-json option to generate the api.json file. No need for copying any dependencies to the build folder. In this case the CLI tool should print the information that it will not use the RAML as a source but the generated JSON file.
I think option 2 is better from the UX perspective. It could be problematic to list all fragments of the RAML file and pass it to the command. I can imagine that it could exceed max number of characters on Windows. Upside is that the user could just replace the RAML file on server. Downside is that the console will use parser and enhancer to build the data structure.
Downside for option 2 is that the user can't just simply replace a RAML file in the build but on the other hand, this is why we have enhancer as a Node module so it can be use in the CI to generate api.json file upload it to the server.
When building the API console from a local RAML file it is now trying to download the RAML file from the build location. But there's no file to download.
Option 1: It should copy the file to the build location. In this case the CLI tool has to accept argument to copy dependency files as well but the user would need to provide them all when using the command.
Option 2: It should automatically set
--use-json
option to generate theapi.json
file. No need for copying any dependencies to the build folder. In this case the CLI tool should print the information that it will not use the RAML as a source but the generated JSON file.I think option 2 is better from the UX perspective. It could be problematic to list all fragments of the RAML file and pass it to the command. I can imagine that it could exceed max number of characters on Windows. Upside is that the user could just replace the RAML file on server. Downside is that the console will use parser and enhancer to build the data structure.
Downside for option 2 is that the user can't just simply replace a RAML file in the build but on the other hand, this is why we have enhancer as a Node module so it can be use in the CI to generate
api.json
file upload it to the server.