You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/src/content/docs/challenges/angular/6-permissions.md
+10-7Lines changed: 10 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,13 +11,16 @@ sidebar:
11
11
12
12
## Information
13
13
14
-
Structural directive is an important concept you will need to master to improve your angular skills and knowledge. This will be the first part of this challenge.
14
+
Structural directives are directives which change the DOM layout by adding and removing DOM elements. This is an important concept you'll need to improve your angular skills and knowledge. This will be the first part of this challenge. For more information check out the [official documentation](https://angular.io/guide/structural-directives).
15
15
16
-
Guard is also very important since you will always need it in every application you build.
16
+
Guards like `CanActivate` or `CanMatch` are also very important, since you'll need it in the most application's you build. If you're not very familiar with route guards, check out this two articles.
17
+
18
+
-[Everything you need to know about route Guard in Angular](https://itnext.io/everything-you-need-to-know-about-route-guard-in-angular-697a062d3198)
19
+
-[Create a route Guard to manage permissions](https://medium.com/@thomas.laforge/create-a-route-guard-to-manage-permissions-26f16cc9a1ca)
17
20
18
21
## Statement
19
22
20
-
In LoginComponent, you will find 6 buttons corresponding to 6 differents user's role.
23
+
In `LoginComponent` you'll find 6 buttons corresponding to 6 different user's role.
21
24
22
25
- Admin
23
26
- Manager
@@ -29,12 +32,12 @@ In LoginComponent, you will find 6 buttons corresponding to 6 differents user's
29
32
30
33
## Step 1
31
34
32
-
In `InformationComponent`, you need to display the correct piece of information for each role using a structural directive.
35
+
In `InformationComponent` you'll need to display the correct piece of information for each role using a structural directive.
33
36
34
37
### Constraints
35
38
36
-
-no`ngIf` or `@if` inside `InformationComponent`
37
-
-importing the store inside `InformationComponent` is not allowed.
39
+
-No`ngIf` or `@if` inside `InformationComponent`.
40
+
-Importing the store inside `InformationComponent` is not allowed.
38
41
39
42
You should end up with something like below:
40
43
@@ -52,4 +55,4 @@ You should end up with something like below:
52
55
53
56
## Step 2
54
57
55
-
In `Routes.ts`, you should route all users to the correct `DashboardComponent` using `CanMatch` guard.
58
+
In `Routes.ts` you should route all users to the correct `DashboardComponent` using `CanMatch` guard.
0 commit comments