@@ -23,7 +23,7 @@ Add this plugin to an Nx workspace:
23
23
ng add @angular-architects/ddd
24
24
```
25
25
26
- Add domains and features:
26
+ Add domains and features manually :
27
27
28
28
```
29
29
ng g @angular-architects/ddd:domain booking
@@ -33,6 +33,39 @@ ng g @angular-architects/ddd:feature cancel --domain booking --app flight-app
33
33
ng g @angular-architects/ddd:feature manage --domain boarding --app flight-app
34
34
```
35
35
36
+ Add domains and features interactively:
37
+
38
+ ```
39
+ ng g @angular-architects/ddd:domain
40
+ > ? What is the name of the domain? booking
41
+ ? Would you like to add an associated application? (y/N) No
42
+
43
+ ng g @angular-architects/ddd:domain
44
+ > ? What is the name of the domain? boarding
45
+ ? Would you like to add an associated application? (y/N) No
46
+
47
+ ng g @angular-architects/ddd:feature
48
+ > ? What is the name of the library? search
49
+ > ? What is the name of the associated domain? booking
50
+ > ? Is this feature lazy loaded? (y/N) No
51
+ > [Optional] What is the associated application? (Leave blank if none) flight-app
52
+ > [Optional] What is the name of the entity to create for this feature? (Leave blank if none) flight
53
+
54
+ ng g @angular-architects/ddd:feature
55
+ > ? What is the name of the library? cancel
56
+ > ? What is the name of the associated domain? booking
57
+ > ? Is this feature lazy loaded? (y/N) No
58
+ > [Optional] What is the associated application? (Leave blank if none) flight-app
59
+ > [Optional] What is the name of the entity to create for this feature? (Leave blank if none)
60
+
61
+ ng g @angular-architects/ddd:feature
62
+ > ? What is the name of the library? manage
63
+ > ? What is the name of the associated domain? boarding
64
+ > ? Is this feature lazy loaded? (y/N) No
65
+ > [Optional] What is the associated application? (Leave blank if none) flight-app
66
+ > [Optional] What is the name of the entity to create for this feature? (Leave blank if none)
67
+ ```
68
+
36
69
This example assumes that you have an app `` flight-app `` in place.
37
70
38
71
These schematics also wire up the individual libs. To see the result, create a dependency graph:
@@ -86,4 +119,4 @@ see https://github.com/angular-architects/ddd-demo
86
119
- [ Recording of session about this architecture] ( https://www.youtube.com/watch?v=94HFD391zkE&t=1s )
87
120
- [ Article series about DDD with Angular] ( https://www.softwarearchitekt.at/aktuelles/sustainable-angular-architectures-1/ )
88
121
- [ Our eBook about this architecture] ( https://leanpub.com/enterprise-angular )
89
- - [ Thomas Burlison's article about facades in Angular] ( https://medium.com/@thomasburlesonIA/push-based-architectures-with-rxjs-81b327d7c32d )
122
+ - [ Thomas Burlison's article about facades in Angular] ( https://medium.com/@thomasburlesonIA/push-based-architectures-with-rxjs-81b327d7c32d )
0 commit comments