Releases: sidebase/nuxt-auth
0.9.4
What's Changed
- fix: violations of upcoming
eslint/no-else-return
oxlint rule by @DonIsaac in #921 - fix(#926): correct and clarify Guest Mode by @phoenix-ru in #929
- release: 0.9.4 by @zoey-kaiser in #930
Full Changelog: 0.9.3...0.9.4
0.9.3
What's Changed
- docs: correct location of session data type definitions by @cngJo in #904
- docs(#906): clarify
origin
documentation by @phoenix-ru in #908 - enh: provide a demo implementation of refresh provider by @phoenix-ru in #901
- docs: fix refreshRequestTokenPointer example by @zoey-kaiser in #912
- docs: laravel-passport.md fix "Learn more" issue link by @holtolee in #909
- enh(#861): Redirect back to requested page after authentication by @andychukse in #870
- release: 0.9.3 by @zoey-kaiser in #916
New Contributors
- @cngJo made their first contribution in #904
- @holtolee made their first contribution in #909
- @andychukse made their first contribution in #870
Full Changelog: 0.9.2...0.9.3
0.9.2
What's Changed
- docs: Fix typo in custom-pages.md by @bahulneel in #894
- fix: update to latest
@nuxt/module-builder
by @danielroe in #888 - fix: cannot set headers after they are sent to the client by @zoey-kaiser in #875
- docs(#897): clarify
authjs
providers usage (next-auth@4) by @phoenix-ru in #898 - fix(#896): set rawRefreshToken default value by @phoenix-ru in #899
- release: 0.9.2 by @zoey-kaiser in #900
New Contributors
- @bahulneel made their first contribution in #894
Full Changelog: 0.9.1...0.9.2
0.9.1
What's Changed
- docs: add 0.9.0 changelog by @zoey-kaiser in #874
- chore: prepare lint script for no-unused-vars by @DonIsaac in #876
- CI: publish preview package versions of PRs by @zoey-kaiser in #884
- fix: remove concurrency check from
pkg.pr.new
workflow by @zoey-kaiser in #885 - fix(#879): do not format
refresh_token
by @zoey-kaiser in #886 - enh(#880): add signInHeaders param to SignIn by @dangercris in #881
- release: 0.9.1 by @zoey-kaiser in #887
New Contributors
- @DonIsaac made their first contribution in #876
- @dangercris made their first contribution in #881
Full Changelog: 0.9.0...0.9.1
0.9.0
Upgrade guide
Hi everyone 👋
In #821 we made a breaking change where we unified the local
and refresh
providers into one!
Therefore, anyone using the refresh
provider, will need to update their configuration after upgrading @sidebase/nuxt-auth
.
We prepared a full upgrade guide, that can be read here.
What's Changed
- fix(#834): Do not refresh on window focus for unprotected pages by @YoshimiShima in #858
- chore: add metadata fields to package.json by @MuhammadM1998 in #864
- fix(#860): make node version requirement less strict by @phoenix-ru in #865
- docs: Add recipes section and copy old recipes by @zoey-kaiser in #868
- chore: add plausible site analytics by @zoey-kaiser in #869
- feat(#673, #523, #848): back-port authjs migration by @phoenix-ru in #849
- feat(#821): Unify
local
andrefresh
providers into one by @zoey-kaiser in #822 - chore: updated ESLint and general housekeeping by @zoey-kaiser in #853
- chore: update docs for
0.9.0
by @zoey-kaiser in #873
New Contributors
- @YoshimiShima made their first contribution in #858
Full Changelog: 0.8.2...0.9.0
0.8.2
What's Changed
- docs: fix typo in self-hosted deployment guide by @dc-shackle in #829
- chore: update dependencies and use pnpm 9 by @phoenix-ru in #839
- fix(#808): only add error to response when it is set by @zoey-kaiser in #809
- docs: add meta tags and generate sitemap by @zoey-kaiser in #841
- fix(docs): title hierarchy in app configuration by @NanamiNakano in #844
- feat(#836)!: unification and flexibility with
AUTH_ORIGIN
by @hywax in #837 - feat: Add refresh token to signOut request body by @MisterNox in #731
- feat: Add httpOnly cookie attribute support by @maximehamou in #847
New Contributors
- @dc-shackle made their first contribution in #829
- @NanamiNakano made their first contribution in #844
- @hywax made their first contribution in #837
- @MisterNox made their first contribution in #731
- @maximehamou made their first contribution in #847
Full Changelog: 0.8.1...0.8.2
0.8.1
What's Changed
- docs: rewrite with vitepress by @zoey-kaiser in #783
- docs(#782): guide on using external urls in endpoints by @zoey-kaiser in #796
- docs: fix typo in external endpoints by @MuhammadM1998 in #798
- docs(#802): wrap endpoints in provider to match nuxt.config.ts by @zoey-kaiser in #804
- docs: fix provider table and made docs more gender-neutral by @zoey-kaiser in #810
- fix(#793): avoid using nitro on client by @phoenix-ru in #817
- fix(#792): do not block login page for refresh provider by @hiroki-otaka in #814
- release: 0.8.1 by @zoey-kaiser in #819
New Contributors
- @hiroki-otaka made their first contribution in #814
Full Changelog: 0.8.0...0.8.1
0.8.0
Upgrade guide
This release contains breaking changes for all providers.
// nuxt.config.ts
export default defineNuxtConfig({
modules: ['@sidebase/nuxt-auth'],
auth: {
- session: {
- enableRefreshOnWindowFocus: true,
- enableRefreshPeriodically: 10000,
- refreshHandler: RefreshHandler
- }
+ sessionRefresh: {
+ enableOnWindowFocus: true,
+ enablePeriodically: 10000,
+ refreshHandler: RefreshHandler
+ }
}
})
RefreshHandler
In #715, we took the first step to improve the behavior and possibilities to customize the Refresh behaviour of your application. In #766 we finalized these changes and improved the previous configuration options. You can define the location of a custom RefreshHandler inside your Nuxt config under auth.sessionRefresh.refreshHandler
.
To customize the session refreshing you can provide a refresh handler. A custom RefreshHandler
requires an init
- and a destroy
-function.
init
will be called when the nuxt application is mounted. Here you may add event listeners and initialize custom refresh behaviour. The method will receive aRefreshHandlerConfig
. The type consists ofenablePeriodically
&enableOnWindowFocus
.destroy
will be called when your app is unmounted. Here you may run your clean up routine e.g. to remove your event listeners.
import type { RefreshHandler } from '@sidebase/nuxt-auth'
// You may also use a plain object with `satisfies RefreshHandler`, of course!
class CustomRefreshHandler implements RefreshHandler {
init (): void {
console.info('Use the full power of classes to customize refreshHandler!')
}
destroy (): void {
console.info(
'Hover above class properties or go to their definition ' +
'to learn more about how to craft a refreshHandler'
)
}
}
export default new CustomRefreshHandler()
If no custom RefreshHandler is defined, the build-in handler will be used.
What's Changed
- Feature: Option to remove server side auth by @KyleSmith0905 in #610
- docs: Added documentation for automatic session refresh by @Hiimphteve in #739
- docs: Adjusted Recommended NextAuth Version by @zoey-kaiser in #741
- fix: fix and improve auto-declaration generation by @phoenix-ru in #747
- feat: Add cookie domain config by @pier-lucRVezy in #736
- fix(types): export interface for module builder type generation by @BobbieGoede in #738
- enh(#742): optimize internal $fetch calls by @phoenix-ru in #750
- release: 0.8.0-alpha.1 by @zoey-kaiser in #752
- fix: opt in to
import.meta.*
properties by @danielroe in #719 - [PR changes #392] feat: move pointer and sessionDataType to the SessionConfig by @valh1996 in #592
- feat: Add support for secure attribute of local/refresh provider cookies by @matteioo in #729
- fix: don't send sign-in options in request payload by @despatates in #755
- fix: fix type generation being faulty by @phoenix-ru in #756
- feat: Add support for custom refresh handling by @blumewas in #715
- release: 0.8.0-alpha.2 by @zoey-kaiser in #757
- 📝 docs: add session config.md by @blumewas in #758
- docs: fix broken links and minor rewording by @morehawes in #767
- enh(#765): refactor
refreshHandler
and session refreshing; fix refresh provider refreshing by @phoenix-ru in #766 - fix: await sendRedirect in auth handler by @DavidDeSloovere in #769
- fix: Added getCurrentInstance check to conditionally register onMounted in useAuthState. by @cip8 in #771
- release: 0.8.0-alpha.3 by @zoey-kaiser in #778
- fix: properly disable
getSession
endpoint for local and refresh by @Armillus in #768 - fix: addDefaultCallback can be set with refresh and local providers by @nojiritakeshi in #710
- release: 0.8.0-rc.1 by @zoey-kaiser in #779
- Revert "fix: properly disable
getSession
endpoint for local and refresh" by @zoey-kaiser in #788 - release: 0.8.0 by @zoey-kaiser in #789
New Contributors
- @Hiimphteve made their first contribution in #739
- @pier-lucRVezy made their first contribution in #736
- @BobbieGoede made their first contribution in #738
- @valh1996 made their first contribution in #592
- @matteioo made their first contribution in #729
- @despatates made their first contribution in #755
- @blumewas made their first contribution in #715
- @morehawes made their first contribution in #767
- @DavidDeSloovere made their first contribution in #769
- @cip8 made their first contribution in #771
- @Armillus made their first contribution in #768
- @nojiritakeshi made their first contribution in #710
Full Changelog: 0.7.2...0.8.0
0.8.0-rc.1
Upgrade guide
This release contains breaking changes for all providers.
// nuxt.config.ts
export default defineNuxtConfig({
modules: ['@sidebase/nuxt-auth'],
auth: {
- session: {
- enableRefreshOnWindowFocus: true,
- enableRefreshPeriodically: 10000,
- refreshHandler: RefreshHandler
- }
+ sessionRefresh: {
+ enableOnWindowFocus: true,
+ enablePeriodically: 10000,
+ refreshHandler: RefreshHandler
+ }
}
})
RefreshHandler
In #715, we took the first step to improve the behavior and possibilities to customize the Refresh behaviour of your application. In #766 we finalized these changes and improved the previous configuration options. You can define the location of a custom RefreshHandler inside your Nuxt config under auth.sessionRefresh.refreshHandler
.
To customize the session refreshing you can provide a refresh handler. A custom RefreshHandler
requires an init
- and a destroy
-function.
init
will be called when the nuxt application is mounted. Here you may add event listeners and initialize custom refresh behaviour. The method will receive aRefreshHandlerConfig
. The type consists ofenablePeriodically
&enableOnWindowFocus
.destroy
will be called when your app is unmounted. Here you may run your clean up routine e.g. to remove your event listeners.
import type { RefreshHandler } from '@sidebase/nuxt-auth'
// You may also use a plain object with `satisfies RefreshHandler`, of course!
class CustomRefreshHandler implements RefreshHandler {
init (): void {
console.info('Use the full power of classes to customize refreshHandler!')
}
destroy (): void {
console.info(
'Hover above class properties or go to their definition ' +
'to learn more about how to craft a refreshHandler'
)
}
}
export default new CustomRefreshHandler()
If no custom RefreshHandler is defined, the build-in handler will be used.
What's Changed
- fix: properly disable
getSession
endpoint for local and refresh by @Armillus in #768 - fix: addDefaultCallback can be set with refresh and local providers by @nojiritakeshi in #710
- release: 0.8.0-rc.1 by @zoey-kaiser in #779
New Contributors
- @Armillus made their first contribution in #768
- @nojiritakeshi made their first contribution in #710
Full Changelog: 0.8.0-alpha.3...0.8.0-rc.1
0.8.0-alpha.3
Upgrade guide
This release contains breaking changes for all providers.
// nuxt.config.ts
export default defineNuxtConfig({
modules: ['@sidebase/nuxt-auth'],
auth: {
- session: {
- enableRefreshOnWindowFocus: true,
- enableRefreshPeriodically: 10000,
- refreshHandler: RefreshHandler
- }
+ sessionRefresh: {
+ enableOnWindowFocus: true,
+ enablePeriodically: 10000,
+ refreshHandler: RefreshHandler
+ }
}
})
RefreshHandler
In #715, we took the first step to improve the behavior and possibilities to customize the Refresh behaviour of your application. In #766 we finalized these changes and improved the previous configuration options. You can define the location of a custom RefreshHandler inside your Nuxt config under auth.sessionRefresh.refreshHandler
.
To customize the session refreshing you can provide a refresh handler. A custom RefreshHandler
requires an init
- and a destroy
-function.
init
will be called when the nuxt application is mounted. Here you may add event listeners and initialize custom refresh behaviour. The method will receive aRefreshHandlerConfig
. The type consists ofenablePeriodically
&enableOnWindowFocus
.destroy
will be called when your app is unmounted. Here you may run your clean up routine e.g. to remove your event listeners.
import type { RefreshHandler } from '@sidebase/nuxt-auth'
// You may also use a plain object with `satisfies RefreshHandler`, of course!
class CustomRefreshHandler implements RefreshHandler {
init (): void {
console.info('Use the full power of classes to customize refreshHandler!')
}
destroy (): void {
console.info(
'Hover above class properties or go to their definition ' +
'to learn more about how to craft a refreshHandler'
)
}
}
export default new CustomRefreshHandler()
If no custom RefreshHandler is defined, the build-in handler will be used.
What's Changed
- 📝 docs: add session config.md by @blumewas in #758
- docs: fix broken links and minor rewording by @morehawes in #767
- enh(#765): refactor
refreshHandler
and session refreshing; fix refresh provider refreshing by @phoenix-ru in #766 - fix: await sendRedirect in auth handler by @DavidDeSloovere in #769
- fix: Added getCurrentInstance check to conditionally register onMounted in useAuthState. by @cip8 in #771
- release: 0.8.0-alpha.3 by @zoey-kaiser in #778
New Contributors
- @morehawes made their first contribution in #767
- @DavidDeSloovere made their first contribution in #769
- @cip8 made their first contribution in #771
Full Changelog: 0.8.0-alpha.2...0.8.0-alpha.3