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

Implement version check and auto-update for zkSync Remix plugin #126

Open
satyambnsal opened this issue Jul 1, 2024 · 1 comment
Open
Assignees
Labels
enhancement New feature or request help wanted Extra attention is needed priority High-priority task
Milestone

Comments

@satyambnsal
Copy link
Contributor

Currently, users may continue to access outdated versions of the zkSync Remix plugin due to browser caching. We need to implement a mechanism that checks for new versions and automatically fetches the latest version when available.
Proposed solution:

Implement a version check system:

Store the current plugin version in a easily accessible location (e.g., a JSON file or API endpoint)
On plugin initialization, compare the local version with the latest available version

Auto-update mechanism:

If a new version is detected, fetch the latest plugin files
Update the local plugin files with the newly fetched version
Reload the plugin to use the new version

Cache-busting strategy:

Implement a cache-busting technique (e.g., appending a version number or timestamp to file URLs) to ensure browsers always fetch the latest files

This enhancement will ensure that users always have access to the most recent version of the plugin, improving the overall user experience and reducing potential issues related to outdated versions.

@varex83
Copy link
Contributor

varex83 commented Jul 1, 2024

The first part is already done, so we can focus on the second one: "Auto-update mechanism"

About third one, I don't see any possible easy solutions like appending the version tag into the plugin URL since it will require updating the URL to plugin in Remix repository. I would propose trying to add some headers to the vite to avoid caching.

@varex83 varex83 added this to the Next release milestone Jul 9, 2024
@varex83 varex83 added enhancement New feature or request help wanted Extra attention is needed priority High-priority task labels Jul 11, 2024
@satyambnsal satyambnsal modified the milestones: Next release, 0.6 Aug 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed priority High-priority task
Projects
Status: 📋 Backlog
Development

No branches or pull requests

2 participants