Skip to content

Commit 80880e6

Browse files
authored
Merge branch 'master' into parameter-components
2 parents 94949dc + 3361658 commit 80880e6

File tree

16 files changed

+5425
-17909
lines changed

16 files changed

+5425
-17909
lines changed

.github/workflows/codeql.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: "CodeQL"
2+
3+
on:
4+
push:
5+
branches: [ "master" ]
6+
pull_request:
7+
branches: [ "master" ]
8+
schedule:
9+
- cron: "44 20 * * 3"
10+
11+
jobs:
12+
analyze:
13+
name: Analyze
14+
runs-on: ubuntu-latest
15+
permissions:
16+
actions: read
17+
contents: read
18+
security-events: write
19+
20+
strategy:
21+
fail-fast: false
22+
matrix:
23+
language: [ javascript ]
24+
25+
steps:
26+
- name: Checkout
27+
uses: actions/checkout@v3
28+
29+
- name: Initialize CodeQL
30+
uses: github/codeql-action/init@v2
31+
with:
32+
languages: ${{ matrix.language }}
33+
queries: +security-and-quality
34+
35+
- name: Autobuild
36+
uses: github/codeql-action/autobuild@v2
37+
38+
- name: Perform CodeQL Analysis
39+
uses: github/codeql-action/analyze@v2
40+
with:
41+
category: "/language:${{ matrix.language }}"

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11
# Changelog
22
All notable changes to this project will be documented in this file.
33

4+
## [0.24.0] - 2023-04-10
5+
### Fixed
6+
- Upgraded dependencies
7+
- Fixed issue with Cancelable promise
8+
- Fixed issue with escaping reserved keywords in schema names
9+
### Added
10+
- Added `--postfixModels` option
11+
412
## [0.23.0] - 2022-06-02
513
### Fixed
614
- Upgraded dependencies

README.md

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
[![NPM][npm-image]][npm-url]
44
[![License][license-image]][license-url]
55
[![Coverage][coverage-image]][coverage-url]
6-
[![Quality][quality-image]][quality-url]
7-
[![Code Climate][climate-image]][climate-url]
86
[![Downloads][downloads-image]][downloads-url]
97
[![Build][build-image]][build-url]
108

@@ -14,7 +12,7 @@
1412
- Frontend ❤️ OpenAPI, but we do not want to use JAVA codegen in our builds
1513
- Quick, lightweight, robust and framework-agnostic 🚀
1614
- Supports generation of TypeScript clients
17-
- Supports generations of Fetch, [Node-Fetch](#node-fetch-support), [Axios](#axios-support), [Angular](#angular-support) and XHR http clients
15+
- Supports generations of Fetch, Node-Fetch, Axios, Angular and XHR http clients
1816
- Supports OpenAPI specification v2.0 and v3.0
1917
- Supports JSON and YAML files for input
2018
- Supports generation through CLI, Node.js and NPX
@@ -86,10 +84,6 @@ Support
8684
[license-image]: http://img.shields.io/npm/l/openapi-typescript-codegen.svg
8785
[coverage-url]: https://codecov.io/gh/ferdikoomen/openapi-typescript-codegen
8886
[coverage-image]: https://img.shields.io/codecov/c/github/ferdikoomen/openapi-typescript-codegen.svg
89-
[quality-url]: https://lgtm.com/projects/g/ferdikoomen/openapi-typescript-codegen
90-
[quality-image]: https://img.shields.io/lgtm/grade/javascript/g/ferdikoomen/openapi-typescript-codegen.svg
91-
[climate-url]: https://codeclimate.com/github/ferdikoomen/openapi-typescript-codegen
92-
[climate-image]: https://img.shields.io/codeclimate/maintainability/ferdikoomen/openapi-typescript-codegen.svg
9387
[downloads-url]: http://npm-stat.com/charts.html?package=openapi-typescript-codegen
9488
[downloads-image]: http://img.shields.io/npm/dm/openapi-typescript-codegen.svg
9589
[build-url]: https://circleci.com/gh/ferdikoomen/openapi-typescript-codegen/tree/master

bin/index.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ const params = program
2121
.option('--exportModels <value>', 'Write models to disk', true)
2222
.option('--exportSchemas <value>', 'Write schemas to disk', false)
2323
.option('--indent <value>', 'Indentation options [4, 2, tabs]', '4')
24-
.option('--postfix <value>', 'Deprecated: Use --postfixServices instead. Service name postfix', 'Service')
2524
.option('--postfixServices <value>', 'Service name postfix', 'Service')
2625
.option('--postfixModels <value>', 'Model name postfix')
2726
.option('--request <value>', 'Path to custom request file')
@@ -43,7 +42,7 @@ if (OpenAPI) {
4342
exportModels: JSON.parse(params.exportModels) === true,
4443
exportSchemas: JSON.parse(params.exportSchemas) === true,
4544
indent: params.indent,
46-
postfixServices: params.postfixServices ?? params.postfix,
45+
postfixServices: params.postfixServices,
4746
postfixModels: params.postfixModels,
4847
request: params.request,
4948
})

bin/index.spec.js

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -69,18 +69,4 @@ describe('bin', () => {
6969
expect(result.stdout.toString()).toContain(`-o, --output <value>`);
7070
expect(result.stderr.toString()).toBe('');
7171
});
72-
73-
it('should still support the deprecated --postfix parameter', () => {
74-
const result = crossSpawn.sync('node', [
75-
'./bin/index.js',
76-
'--input',
77-
'./test/spec/v3.json',
78-
'--output',
79-
'./test/generated/bin',
80-
'--postfix',
81-
'Service',
82-
]);
83-
expect(result.stdout.toString()).toBe('');
84-
expect(result.stderr.toString()).toBe('');
85-
});
8672
});

docs/angular-support.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ If you want to generate the Angular based client then you can specify `--client
99
The Angular client has been tested with the following versions:
1010

1111
```
12-
"@angular/common": "14.0.x",
13-
"@angular/core": "14.0.x",
12+
"@angular/common": "15.0.x",
13+
"@angular/core": "15.0.x",
1414
"rxjs": "7.5.x",
1515
```
1616

0 commit comments

Comments
 (0)