Skip to content
This repository was archived by the owner on Dec 26, 2025. It is now read-only.
This repository was archived by the owner on Dec 26, 2025. It is now read-only.

[Feature Request] An option to automatically add location.pathname to keys #243

Description

@xiety

When hosting Blazor Wasm on Github Pages, all my repositories have the same origin. So localStorage items are shared among all my repositories.

So, I want an option to prefix every key with the current location.pathname

Workaround is to patch JS methods like in this example:

https://github.com/TomasHubelbauer/github-pages-local-storage/blob/main/index.js

localStorage.constructor.prototype.getItem = (key) => getItem.apply(localStorage, [location.pathname + ':' + key]);

Or manually add prefixes to all method calls.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Feature RequestRequest to add a new featureTriageIssue needs to be triaged

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions