Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Enable Visual Studio Code to generate constructor from Typescript class

I use Visual Studio Code to develop Angular 2 apps in Typescript. Is there any means to save the effort of writing constructors with its parameter list myself?

Would be great if the IDE could generate the constructor based on the class members like e.g. Eclipse can do it for Java.

like image 361
Emdee Avatar asked Dec 31 '16 12:12

Emdee


1 Answers

Just install TypeScript Toolbox :

https://marketplace.visualstudio.com/items?itemName=DSKWRK.vscode-generate-getter-setter

You can generate Constructor, Getter and setters ....

like image 124
Charlie Rabiller Avatar answered Oct 29 '22 20:10

Charlie Rabiller