This extension allows quickly scaffold angular 2 file templates in VS Code project.
Inspired by angular-cli (https://github.com/angular/angular-cli)
- Fixed support for custom app structure
- It's just angular
- Module style ext fix - thanks to Sam Lin
- Fix incorrect extension in component generation
- CPU usage improvements
- Support for non angular-cli file-structure, code should reside in 'app' folder by default
- Fixed import declarations to incorrect module
- Added route class generat template
- Angular-Files now supports angular-cli.json and you can use custom prefixes, different style extensions.
- Note: if you not using angular-cli it is possible to add angular-cli.json to customize file generatiion.
- Fixed serivces was incorrectly imported to module declarations
- Fixed import declarations to closest module
- angular-cli removed due to slowness
- app.module added automatic import of dependencies
- Integrated angular-cli for file generation
Right click on a file or a folder in your current project. You can find multiple options been added to the context menu:
Menu Options |
---|
New Component |
New Directive |
New Pipe |
New Service |
New Module |
Menu Options |
---|
New Class |
New Interface |
New Enum |
** Override default configuration like app prefix and style: ** Create a angular-cli.json (can be used without angular-cli):
{
"apps":[
{
"root":"src",
"prefix":"app"
}
],
"defaults":{
"styleExt":"css"
}
}
The naming of the files as well as the (boilerplate) snippets are based on the official Angular Style Guide
- Install Visual Studio Code 1.5.0 or higher
- Launch Code
- From the command palette
Ctrl
-Shift
-P
(Windows, Linux) orCmd
-Shift
-P
(OSX) - Select
Install Extension
- Type
angular files
and press enter - Reload Visual Studio Code
Important: This extension due to the nature of it's purpose will create files on your hard drive and if necessary create the respective folder structure. While it should not override any files during this process, I'm not giving any guarantees or take any responsibility in case of lost data.
MIT