Fork the Repo Find Help Stack Overflow

# Directive

Edit this Page

### Directive

Generates a directive.

Example:

    yo angular-fullstack:directive myDirective
    [?] What module name would you like to use? myApp.myDirective
    [?] Where would you like to create this directive? client/app/
    [?] Does this directive need an external html file? Yes

Produces:

    client/app/myDirective/myDirective.directive.js
    client/app/myDirective/myDirective.directive.spec.js
    client/app/myDirective/myDirective.html
    client/app/myDirective/myDirective.scss

Simple directive without an html file

Example:

    yo angular-fullstack:directive simple
    [?] What module name would you like to use? myApp.simple
    [?] Where would you like to create this directive? client/app/
    [?] Does this directive need an external html file? No

Produces:

    client/app/simple/simple.directive.js
    client/app/simple/simple.directive.spec.js

### Contributors