Skip to content
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

Fix deprecations, replace cookies with localstorage #322

Draft
wants to merge 7 commits into
base: 1.x
Choose a base branch
from

Conversation

millnut
Copy link
Member

@millnut millnut commented May 3, 2024

  • Fix a deprecation on spaceless that was missed (see https://www.drupal.org/project/drupal/issues/3094850)
  • Remove full-page-alert-banner.es6.js, Drupal doesn't use es6 for builds anymore
  • Replace cookie functionality with LocalStorage
    • Cookie storage limit 4KB
    • LocalStorage limit 5MB
  • Refactor in plain/vanilla javascript to remove jQuery dependency

Copy link
Member

@ekes ekes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@andybroomfield
Copy link
Contributor

Thanks @millnut.
I'd pause on this for now as js-cookie includes a remote CDN loading dependency unless people know to include it.
Since that would be springing it on people in a patch release, I'd rather wait until that is released before we merge this.

I still think we can rewrite the cookie logic to not require js-cookie if someone has time.

@andybroomfield
Copy link
Contributor

andybroomfield commented May 7, 2024

Is this template actully used anywhere? it does not appear in any other custom entitiy. Maybe thats why we havn't noticed it.

@millnut
Copy link
Member Author

millnut commented May 7, 2024

Thanks for checking @andybroomfield I wasn't aware it used a remote CDN. If I have the time I'll rewrite in plain javascript and we can probably remove this requirement altogether

@finnlewis finnlewis marked this pull request as draft May 7, 2024 11:11
@millnut millnut changed the title Fix deprecations Fix deprecations, replace cookies with localstorage May 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants