-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs: add migration section for v2 #40
Conversation
README.md
Outdated
@@ -2,28 +2,65 @@ | |||
|
|||
A JavaScript library for managing authentication for [Storyblok](https://www.storyblok.com) apps. | |||
|
|||
## Migrating v1 to v2 | |||
|
|||
The `@storyblok/app-extension-auth` v1 stored the access token in a cookie. However, v2 now offers an adapter pattern, allowing you to store the access token elsewhere, such as in a dedicated database. And here are the breaking changes: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am wondering if this is a bit misleading, as we abstracted the logic to the adapter pattern however the storage inside a DB and enabling passing a custom adapter is not possible at the moment right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure if I follow you. How is it not possible?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently the user cannot pass their own adapter to authHandler or the sessionStore.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh I didn't realize we removed adapter from AuthHandlerParams. I'll modify this.
docs: update
What?
This PR adds a migration section to the README.