Skip to content

Commit eee326e

Browse files
add .referrer token
1 parent c611900 commit eee326e

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

articles/static-web-apps/authentication-authorization.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,14 @@ For example:
7070
<a href="/.auth/login/github?post_login_redirect_uri=https://zealous-water.azurestaticapps.net/success">Login</a>
7171
```
7272

73+
Alternatively, if you want to redirect back to the referring page, you can use the `.referrer` token.
74+
75+
For example:
76+
77+
```html
78+
<a href="/.auth/login/github?post_login_redirect_uri=.referrer">Login</a>
79+
```
80+
7381
## Logout
7482

7583
The `/.auth/logout` route logs users out from the website. You can add a link to your site navigation to allow the user to log out as shown in the following example.

0 commit comments

Comments
 (0)