forked from atinux/nuxt-auth-utils
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* main: chore(release): v0.0.15 chore: up deps feat: added aws cognito provider (atinux#36) feat: add auth0 connection parameter to config (atinux#39) fix: replace encoded space characters with regular spaces (atinux#40) chore(release): v0.0.14 chore: update deps feat: added keycloak as oauth provider (atinux#23) chore: test bundler module resolution (atinux#32) chore(release): v0.0.13 chore: rename session from verify to fetch chore(release): v0.0.12 fix: correct arguments for hooks chore(release): v0.0.11 feat: add sessionHooks to extend user sessions
- Loading branch information
Showing
23 changed files
with
2,419 additions
and
771 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# enable TypeScript bundler module resolution - https://www.typescriptlang.org/docs/handbook/modules/reference.html#bundler | ||
experimental.typescriptBundlerResolution=true |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,85 @@ | ||
# Changelog | ||
|
||
|
||
## v0.0.15 | ||
|
||
[compare changes](https://github.com/Atinux/nuxt-auth-utils/compare/v0.0.14...v0.0.15) | ||
|
||
### 🚀 Enhancements | ||
|
||
- Add auth0 connection parameter to config ([#39](https://github.com/Atinux/nuxt-auth-utils/pull/39)) | ||
- Added aws cognito provider ([#36](https://github.com/Atinux/nuxt-auth-utils/pull/36)) | ||
|
||
### 🩹 Fixes | ||
|
||
- Replace encoded space characters with regular spaces ([#40](https://github.com/Atinux/nuxt-auth-utils/pull/40)) | ||
|
||
### 🏡 Chore | ||
|
||
- Up deps ([a7bd06b](https://github.com/Atinux/nuxt-auth-utils/commit/a7bd06b)) | ||
|
||
### ❤️ Contributors | ||
|
||
- Sébastien Chopin ([@Atinux](http://github.com/Atinux)) | ||
- Dvir Hazout <[email protected]> | ||
- Silvio Eckl <[email protected]> | ||
- Ahmed Rangel ([@ahmedrangel](http://github.com/ahmedrangel)) | ||
|
||
## v0.0.14 | ||
|
||
[compare changes](https://github.com/Atinux/nuxt-auth-utils/compare/v0.0.13...v0.0.14) | ||
|
||
### 🚀 Enhancements | ||
|
||
- Added keycloak as oauth provider ([#23](https://github.com/Atinux/nuxt-auth-utils/pull/23)) | ||
|
||
### 🏡 Chore | ||
|
||
- Test bundler module resolution ([#32](https://github.com/Atinux/nuxt-auth-utils/pull/32)) | ||
- Update deps ([9d6b258](https://github.com/Atinux/nuxt-auth-utils/commit/9d6b258)) | ||
|
||
### ❤️ Contributors | ||
|
||
- Sébastien Chopin ([@Atinux](http://github.com/Atinux)) | ||
- Yue JIN | ||
- Daniel Roe <[email protected]> | ||
|
||
## v0.0.13 | ||
|
||
[compare changes](https://github.com/Atinux/nuxt-auth-utils/compare/v0.0.12...v0.0.13) | ||
|
||
### 🏡 Chore | ||
|
||
- Rename session from verify to fetch ([10694e9](https://github.com/Atinux/nuxt-auth-utils/commit/10694e9)) | ||
|
||
### ❤️ Contributors | ||
|
||
- Sébastien Chopin ([@Atinux](http://github.com/Atinux)) | ||
|
||
## v0.0.12 | ||
|
||
[compare changes](https://github.com/Atinux/nuxt-auth-utils/compare/v0.0.11...v0.0.12) | ||
|
||
### 🩹 Fixes | ||
|
||
- Correct arguments for hooks ([6e0193e](https://github.com/Atinux/nuxt-auth-utils/commit/6e0193e)) | ||
|
||
### ❤️ Contributors | ||
|
||
- Sébastien Chopin ([@Atinux](http://github.com/Atinux)) | ||
|
||
## v0.0.11 | ||
|
||
[compare changes](https://github.com/Atinux/nuxt-auth-utils/compare/v0.0.10...v0.0.11) | ||
|
||
### 🚀 Enhancements | ||
|
||
- Add sessionHooks to extend user sessions ([c470319](https://github.com/Atinux/nuxt-auth-utils/commit/c470319)) | ||
|
||
### ❤️ Contributors | ||
|
||
- Sébastien Chopin ([@Atinux](http://github.com/Atinux)) | ||
|
||
## v0.0.10 | ||
|
||
[compare changes](https://github.com/Atinux/nuxt-auth-utils/compare/v0.0.9...v0.0.10) | ||
|
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
export default defineNitroPlugin(() => { | ||
sessionHooks.hook('fetch', async (session) => { | ||
// Extend User Session | ||
// Or throw createError({ ... }) if session is invalid | ||
session.extended = { | ||
fromHooks: true | ||
} | ||
}) | ||
|
||
sessionHooks.hook('clear', async (session) => { | ||
// Log that user logged out | ||
console.log('User logged out') | ||
}) | ||
}) | ||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
export default oauth.cognitoEventHandler({ | ||
async onSuccess(event, { user }) { | ||
await setUserSession(event, { | ||
user: { | ||
cognito: user, | ||
}, | ||
loggedInAt: Date.now() | ||
}) | ||
|
||
return sendRedirect(event, '/') | ||
} | ||
}) |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
export default oauth.keycloakEventHandler({ | ||
async onSuccess(event, { user }) { | ||
await setUserSession(event, { | ||
user: { | ||
keycloak: user, | ||
}, | ||
loggedInAt: Date.now(), | ||
}) | ||
|
||
return sendRedirect(event, '/') | ||
}, | ||
}) |
Oops, something went wrong.