Skip to content

Commit

Permalink
chore: support es6 when generate api model
Browse files Browse the repository at this point in the history
  • Loading branch information
nguyentoanit committed Mar 5, 2021
1 parent d8f42e7 commit 7b4d611
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion gulpfile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ async function fetchContentsByPath(repoPath = 'models'): Promise<GithubObject[]>
function generateModel(model: GithubObject) {
const outputFolder = path.basename(path.dirname(model.path))
const out = `src/api-models/${outputFolder}`
return `openapi-generator-cli generate -g typescript-axios -o ${out} -i ${model.download_url}`
return `openapi-generator-cli generate -g typescript-axios --additional-properties=supportsES6=true -o ${out} -i ${model.download_url}`
// TODO: run scripts to generate models
}

Expand Down
1 change: 1 addition & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
"ES2019",
"DOM"
],
"noImplicitAny": false,
"target": "ES2019"
},
"include": [
Expand Down

0 comments on commit 7b4d611

Please sign in to comment.