File tree Expand file tree Collapse file tree 11 files changed +1170
-2560
lines changed Expand file tree Collapse file tree 11 files changed +1170
-2560
lines changed Original file line number Diff line number Diff line change 1
1
# Changelog
2
2
3
3
4
+ ## v0.0.10
5
+
6
+ [ compare changes] ( https://github.com/Atinux/nuxt-auth-utils/compare/v0.0.9...v0.0.10 )
7
+
8
+ ### 🚀 Enhancements
9
+
10
+ - Added linkedIn auth provider ([ #13 ] ( https://github.com/Atinux/nuxt-auth-utils/pull/13 ) )
11
+
12
+ ### 🩹 Fixes
13
+
14
+ - Add audience to auth0 runtime config types ([ #27 ] ( https://github.com/Atinux/nuxt-auth-utils/pull/27 ) )
15
+
16
+ ### 📖 Documentation
17
+
18
+ - Add LinkedIn in providers ([ c9b9925] ( https://github.com/Atinux/nuxt-auth-utils/commit/c9b9925 ) )
19
+
20
+ ### 🏡 Chore
21
+
22
+ - Update deps ([ bb3a510] ( https://github.com/Atinux/nuxt-auth-utils/commit/bb3a510 ) )
23
+
24
+ ### ❤️ Contributors
25
+
26
+ - Sébastien Chopin ([ @Atinux ] ( http://github.com/Atinux ) )
27
+ - José Manuel Madriaza Caravia
28
+ - H+ < serdar@justserdar.dev >
29
+
4
30
## v0.0.9
5
31
6
32
[ compare changes] ( https://github.com/Atinux/nuxt-auth-utils/compare/v0.0.8...v0.0.9 )
Original file line number Diff line number Diff line change @@ -154,6 +154,7 @@ It can also be set using environment variables:
154
154
- Discord
155
155
- GitHub
156
156
- Google
157
+ - LinkedIn
157
158
- Microsoft
158
159
- Spotify
159
160
- Twitch
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " nuxt-auth-utils" ,
3
- "version" : " 0.0.9 " ,
3
+ "version" : " 0.0.10 " ,
4
4
"description" : " Minimalist Auth module for Nuxt with SSR" ,
5
5
"repository" : " Atinux/nuxt-auth-utils" ,
6
6
"license" : " MIT" ,
36
36
"ohash" : " ^1.1.3"
37
37
},
38
38
"devDependencies" : {
39
- "@iconify-json/simple-icons" : " ^1.1.79 " ,
39
+ "@iconify-json/simple-icons" : " ^1.1.82 " ,
40
40
"@nuxt/devtools" : " latest" ,
41
41
"@nuxt/eslint-config" : " ^0.2.0" ,
42
42
"@nuxt/module-builder" : " ^0.5.4" ,
43
43
"@nuxt/schema" : " ^3.8.2" ,
44
44
"@nuxt/test-utils" : " ^3.8.1" ,
45
- "@nuxt/ui" : " ^2.10 .0" ,
46
- "@nuxt/ui-pro" : " ^0.4.2 " ,
47
- "@types/node" : " ^20.9.3 " ,
45
+ "@nuxt/ui" : " ^2.11 .0" ,
46
+ "@nuxt/ui-pro" : " ^0.5.0 " ,
47
+ "@types/node" : " ^20.10.4 " ,
48
48
"changelogen" : " ^0.5.5" ,
49
- "eslint" : " ^8.54 .0" ,
49
+ "eslint" : " ^8.55 .0" ,
50
50
"nuxt" : " ^3.8.2" ,
51
- "typescript" : " ^5.3.2 " ,
52
- "vitest" : " ^0.34.6 " ,
53
- "vue-tsc" : " ^1.8.22 "
51
+ "typescript" : " ^5.3.3 " ,
52
+ "vitest" : " ^1.0.2 " ,
53
+ "vue-tsc" : " ^1.8.25 "
54
54
}
55
55
}
Original file line number Diff line number Diff line change @@ -24,4 +24,7 @@ NUXT_OAUTH_DISCORD_CLIENT_ID=
24
24
NUXT_OAUTH_DISCORD_CLIENT_SECRET =
25
25
# Battle.net OAuth
26
26
NUXT_OAUTH_BATTLEDOTNET_CLIENT_ID =
27
- NUXT_OAUTH_BATTLEDOTNET_CLIENT_SECRET =
27
+ NUXT_OAUTH_BATTLEDOTNET_CLIENT_SECRET =
28
+ # LinkedIn
29
+ NUXT_OAUTH_LINKEDIN_CLIENT_ID =
30
+ NUXT_OAUTH_LINKEDIN_CLIENT_SECRET =
Original file line number Diff line number Diff line change @@ -49,6 +49,12 @@ const providers = computed(() => [
49
49
to: ' /auth/microsoft' ,
50
50
disabled: Boolean (user .value ?.microsoft ),
51
51
icon: ' i-simple-icons-microsoft' ,
52
+ },
53
+ {
54
+ label: user .value ?.linkedin ?.email || ' LinkedIn' ,
55
+ to: ' /auth/linkedin' ,
56
+ disabled: Boolean (user .value ?.linkedin ),
57
+ icon: ' i-simple-icons-linkedin' ,
52
58
}
53
59
54
60
].map (p => ({
Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ declare module '#auth-utils' {
9
9
microsoft ?: any ;
10
10
discord ?: any
11
11
battledotnet ?: any
12
+ linkedin ?: any
12
13
}
13
14
loggedInAt : number
14
15
}
Original file line number Diff line number Diff line change
1
+ export default oauth . linkedinEventHandler ( {
2
+ config : {
3
+ emailRequired : true
4
+ } ,
5
+ async onSuccess ( event , { user } ) {
6
+ await setUserSession ( event , {
7
+ user : {
8
+ linkedin : user ,
9
+ } ,
10
+ loggedInAt : Date . now ( )
11
+ } )
12
+
13
+ return sendRedirect ( event , '/' )
14
+ }
15
+ } )
You can’t perform that action at this time.
0 commit comments