3

WebStorm (Version >= 2006.2.EAP) provides Angular-CLI to create new Angular2 Projects out of the box.

The question now is: How can I create a new route (with all the necessary files: component, html-tpl, spec.ts, e2e.specs, etc..) on the fly within WebStorm? "Right-Click > Create a new route" does not exist. Can someone help me further?

LazyOne
  • 158,824
  • 45
  • 388
  • 391

2 Answers2

0

WebStorm provides no support for ng generate. If you miss it, please feel free to create a feature request in youtrack. for now I can only suggest using built-in terminal to run ng generate route <route/to/route-component>

lena
  • 90,154
  • 11
  • 145
  • 150
0

Make sure you have the Angular plugin (it is called AngularJS even though it supports Angular2.)

In the File / New / AngularCLI menu you can choose "route" to create a new route. You can also assign a shortcut key to open the plugin's Angular CLI dialog.

Maor
  • 650
  • 1
  • 6
  • 13