Created
February 5, 2026 10:57
-
-
Save docsallover/f1fa02ad2934498edde7c531f76dabb4 to your computer and use it in GitHub Desktop.
Conditional Logic (@if)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @if (user.isLoggedIn) { | |
| <p>Welcome back, {{ user.name }}!</p> | |
| } @else if (user.isGuest) { | |
| <p>Please sign up.</p> | |
| } @else { | |
| <p>Identify yourself.</p> | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment