swagger-editor
swagger-editor copied to clipboard
SwaggerEditor@next(standalone): initial default language should reside locally
Current: external https call for a definition
Desired: local retrieval of a yaml fixture
Context: current external https call enables easy sync with latest available AsyncAPI definition. However, on public project release, we should not rely on external resources. This maintains existing behavior to be usable inside user's intranets.
Sidenote, we'll likely want to continue to promote Petstore - OAS3.0 rather than AsyncAPI. :)
@tim-lai are you saying that the AsyncAPI definition isn't embedded? I think it would make a good plugin (one or more) for those definitions. So it's not embedded in core code and doesn't require HTTP calls in the demo site (ie *.swagger.io) site.
are you saying that the AsyncAPI definition isn't embedded? I think it would make a good plugin (one or more) for those definitions. So it's not embedded in core code and doesn't require HTTP calls in the demo site (ie *.swagger.io) site
Correct. The AsyncAPI definition is not currently embedded. Partially reason was to more easily keep up with definition changes.
Plugin(s) to provide definitions is a good idea.
Although not enabled, this is now possible using the REACT_APP_DEFINITION_FILE environment flag. There exists a sample setting in .env as well as a fixture /public/static/petstore-oas3.yml.