1.0.3 • Published 3 years ago

@humwing/swagger-code-gen v1.0.3

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

安装

yarn add @humwing/swagger-code-gen

使用

const api = require('@humwing/swagger-code-gen')
const path = require('path')
api.code2ts({
  template: {},
  filepath: path.resolve('./api'),
  swaggerApiUrl: 'http://example.com/common/v2/api-docs?group=api'
})
api.code2js({
  filepath: path.resolve('./api.js'),
  swaggerApiUrl: 'http://example.com/common/v2/api-docs?group=api'
})