https://github.com/dotupnet/dotup-vscode-interface-generator
vscode extension that generates interface from typescript class
https://github.com/dotupnet/dotup-vscode-interface-generator
interface-builder typescript typescript-generator vscode vscode-extension
Last synced: about 14 hours ago
JSON representation
vscode extension that generates interface from typescript class
- Host: GitHub
- URL: https://github.com/dotupnet/dotup-vscode-interface-generator
- Owner: dotupNET
- Created: 2019-03-05T20:57:36.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2019-03-13T11:21:58.000Z (about 7 years ago)
- Last Synced: 2025-07-16T10:05:36.990Z (10 months ago)
- Topics: interface-builder, typescript, typescript-generator, vscode, vscode-extension
- Language: TypeScript
- Homepage:
- Size: 37.5 MB
- Stars: 5
- Watchers: 1
- Forks: 1
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
Awesome Lists containing this project
README
# Interface generator for Visual Studio Code
## Description
Interface generator is a VSCode Extension which creates an interface definition from a typescript class. Supports import statements, comments, public properties and methods, generics and optional.
`Given class:`
```typescript
export class ExtendsOnly extends ABC implements DEF {
public NumberProperty: number = 2;
OptionalStringProperty?: string;
}
```
Since interfaces can not implement anything, `implements DEF` is omitted.
`Generated interface`
```typescript
export interface IExtendsOnly extends ABC {
NumberProperty: number;
OptionalStringProperty?: string;
}
```

## Installation
You can browse and install extensions from within VS Code. Press `Ctrl+P` and narrow down the list commands by typing `ext install dotup-vscode-interface-generator`.
https://marketplace.visualstudio.com/items?itemName=dotup.dotup-vscode-interface-generator
## Usage
### 1. Open a typescript file with one or more class definitions.

### 2. Press `Ctrl+Shift+P` to see all commands and start typing `Generate interface` and hit `Enter`.

The extension creates a new file in the same folder as the source file.
The new file has the name of the source file prefixed with `I`.
Existing files will be overwritten!

## Release Notes
### 1.0.15
Fixes/Features:
- Packages not included
## Release Notes
### 1.0.14
Fixes/Features:
- Explorer context menu "Generate interface"
- Error handling
### 1.0.13
Fixes/Features:
- Update readme :)
### 1.0.12
Fixes/Features:
- [fix #1](https://github.com/dotupNET/dotup-vscode-interface-generator/issues/1)
### 1.0.11
Fixes/Features:
- take over comments ( For classes, methods and properties )
### 1.0.10
Fixes/Features:
- Readme: pictures not shown.
- Readme: Wrong 'Generate interface' example
- Icon added
- dependencies missed
- Wrong target path on Multi-root Workspaces
- prefix on interface name was missing
- video added
TODO:
- take over comments ( For classes, methods and properties )
**Enjoy!**