Skip to content

Commit ca7970c

Browse files
committed
Add README.md for TypeScript Client Generator with installation and usage instructions
1 parent 8a08794 commit ca7970c

2 files changed

Lines changed: 36 additions & 0 deletions

File tree

README.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# TypeScript Client Generator
2+
3+
A .NET tool for generating TypeScript API clients from OpenAPI specifications.
4+
5+
## Installation
6+
7+
```bash
8+
dotnet tool install --global TypescriptClientGenerator
9+
```
10+
11+
## Usage
12+
13+
```bash
14+
typescript-client-generator --input <openapi.json> --output <client.ts>
15+
```
16+
17+
### Options
18+
19+
| Option | Alias | Description | Required |
20+
|--------|-------|-------------|----------|
21+
| `--input` | `-i` | The OpenAPI JSON file to generate a client from | Yes |
22+
| `--output` | `-o` | The output TypeScript file (default: `generated.ts`) | No |
23+
24+
### Example
25+
26+
```bash
27+
typescript-client-generator --input api-spec.json --output api-client.ts
28+
```
29+
30+
## License
31+
32+
MIT

TypescriptClientGenerator/TypescriptClientGenerator.csproj

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,8 @@
2121
<PackageReference Include="System.CommandLine" Version="2.0.2" />
2222
</ItemGroup>
2323

24+
<ItemGroup>
25+
<None Include="../README.md" Pack="true" PackagePath="/"/>
26+
</ItemGroup>
27+
2428
</Project>

0 commit comments

Comments
 (0)