Skip to content

Create Model from loopback-workspace api /ModelDefinitions - Swagger Object not getting updated #140

Description

@pktippa

When we create a new model using the loopback-workspace(default :4800/explorer) api POST /ModelDefinitions and calling the loopback-component-explorer to update the newly created models, see below code

      var explorer = require('loopback-component-explorer');
      var restApiRoot = app.get('restApiRoot');
      var explorerApp = explorer.routes(app, { basePath: restApiRoot });
      app.use('/explorer', explorerApp);

the response for :3000/explorer/swagger.json does not have the newly created models, since the swaggerObject in the index.js does not getting updated and returning updated JSON.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions