-
Notifications
You must be signed in to change notification settings - Fork 3
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 UPGRADE guide for version 3 #402
base: release/v3
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for cookie-consent-manager ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
8053b5b
to
0151d80
Compare
0151d80
to
94c2dca
Compare
94c2dca
to
c1af73c
Compare
Release 3.0 includes backward-incompatible changes, including changes in the underlying vanilla-cookieconsent library, | ||
which has also been upgraded from version 2 to 3. | ||
|
||
This guide summarizes relevant changes in both `almacareer/cookie-consent` and `(vanilla-cookieconsent)[https://github.com/orestbida/cookieconsent]` |
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.
suggestion:
This guide summarizes relevant changes in both `almacareer/cookie-consent` and `(vanilla-cookieconsent)[https://github.com/orestbida/cookieconsent]` | |
This guide summarizes relevant changes in both `@almacareer/cookie-consent` and `(vanilla-cookieconsent)[https://github.com/orestbida/cookieconsent]` |
This guide summarizes relevant changes in both `almacareer/cookie-consent` and `(vanilla-cookieconsent)[https://github.com/orestbida/cookieconsent]` | ||
library to help you upgrade your codebase. | ||
|
||
## Library npm namespace changed to `@almacareer` |
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.
suggestion:
## Library npm namespace changed to `@almacareer` | |
## Library npm scope changed to `@almacareer` |
Technically, it is a scope - https://docs.npmjs.com/cli/v9/using-npm/scope
+"@almacareer/cookie-consent": "^3.0.0" | ||
``` | ||
|
||
If you use the library via CDN, update URL to styles and script: |
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.
suggestion:
If you use the library via CDN, update URL to styles and script: | |
If you use the library via CDN, update the URL to styles and script: |
|
||
Also, the typescript type has been renamed from `LmcCookieConsentManager` to `CookieConsentManager`. | ||
|
||
## Data attribute to open the cookie preference window changed |
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.
suggestion:
## Data attribute to open the cookie preference window changed | |
## The data attribute to open the cookie preference window has changed |
|
||
## Data attribute to open the cookie preference window changed | ||
|
||
The `data-cc` attribute used to open the cookie settings window has been changed from `c-settings` to `show-preferencesModal`. |
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.
suggestion:
The `data-cc` attribute used to open the cookie settings window has been changed from `c-settings` to `show-preferencesModal`. | |
The `data-cc` attribute that opened the cookie settings window has been changed from `c-settings` to `show-preferencesModal`. |
``` | ||
|
||
> [!NOTE] | ||
> It is legally required to provide the user a link to change cookie preferences even after the consent was given for the first time. |
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.
suggestion:
> It is legally required to provide the user a link to change cookie preferences even after the consent was given for the first time. | |
> It is legally required to provide the user with a link to change cookie preferences even after the first consent is given |
## Cookie has been renamed | ||
|
||
The cookie storing the consent data has been changed from `lmc_ccm` to `almacareer_ccm`. If you directly read the cookie value | ||
(either on backend or on frontend), you need to update the cookie name. |
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.
suggestion:
(either on backend or on frontend), you need to update the cookie name. | |
(either on the backend or on the frontend), you need to update the cookie name. |
> This is expected and inevitable behavior with this change, as there is no legal way to migrate the old cookie to the | ||
> new one, as we technically can't transfer the validity period of the old consent to the new cookie. | ||
|
||
## Cookie content structure changed |
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.
suggestion:
## Cookie content structure changed | |
## The cookie content structure has changed |
} | ||
``` | ||
|
||
## Data atribute to run third party scripts changed |
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.
suggestion:
## Data atribute to run third party scripts changed | |
## Data attribute to run third-party scripts has changed |
To be in line with the `vanilla-cookieconsent` library terminology, the term "preferences" is used instead of "settings". | ||
If you used `translationOverrides` configuration, the key `settingsModalMoreInfo` has been renamed to `preferencesModalMoreInfo`. | ||
|
||
## Secondary button mode config removed |
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.
suggestion:
## Secondary button mode config removed | |
## The secondary button mode config was removed |
|
||
Configuration option `secondaryButtonMode` has been removed. | ||
|
||
The consent dialog now always has primary button "Accept all" and secondary button "Accept necessary" |
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.
suggestion:
The consent dialog now always has primary button "Accept all" and secondary button "Accept necessary" | |
The consent dialog now always has a primary button "Accept all" and a secondary button "Accept necessary" |
## Other notable changes | ||
|
||
- Legacy CommonJS support (CJS) has been removed. Use ESM import syntax instead. | ||
- `cookieTable` configuration does not affect in any way any cookies. Cookie table is used only for listing the cookies in preferences modal. |
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.
suggestion:
- `cookieTable` configuration does not affect in any way any cookies. Cookie table is used only for listing the cookies in preferences modal. | |
- `cookieTable` configuration does not affect in any way any cookies. The cookie table is used only for listing the cookies in the preferences modal. |
I have run your docs through the Grammarly app and added some suggestions. |
WIP, but should contain almost everything notable.