@plugin-web-update-notification/vite weekly downloads statistics
By plugin-web-update-notification (2 listings) · npm · Vite plugins
Vite plugin for detect web page updates and notify.
@plugin-web-update-notification/vite has 5,506 recorded weekly downloads on npm, a decrease of 29.4% over the past 30 days, ranking #1068 of 2,256 tracked listings.
About @plugin-web-update-notification/vite
English | 简体中文
plugin-web-update-notification
Detect webpage updates and notify user to reload. support vite, umijs and webpack.
Take the git commit hash (also support svn revision number、package.json version、build timestamp、custom) as the version number, and write version into json file. The client polls the version of the server (visibilitychange or focus event assistant), compares it with the local one, and if it is not the same, notifies the user to refresh the page (you can custom behavior).
When to check for updates (fetch version.json) ?
- first load page. 2. poll (default: 10601000 ms). 3. script resource loading failure detected (404 ?). 4. when the tab page is refocus or revisible.
Why
Some users do not have the habit of closing web pages. If the front-end page is updated, the user page has always been a historical version, any there may be report an error (file 404) or a white screen.
Install
Usage
vite | umi | webpack
Important: Disable index.html caching!
If index.html is cached, the update notification may still appear after refreshing, so it is necessary to disable the caching of index.html. This is also a best practice for deploy SPA applications.
To disable caching through nginx:
Directly disable caching through html meta tags:
Vite
basic usage
custom notification text
internationalization
hidden default notification, listener to update event and custom behavior.
Umijs
webpack
suggest: disabled index.html cache
webUpdateNotice Options
ts • logVersion: (version) => { • console.log(version: %c${version}, 'color: #1890ff') // this is the default behavior • } • ts document.body.addEventListener('plugin_web_update_notice', (e) => { const { version, options } = e.detail // write some code, show your custom notification and etc. alert('System update!') }) • `
export Functions
| name | params | describe |
| window.pluginWebUpdateNotice_.setLocale | locale(preset: zh_CN、zh_TW、en_US) | set locale | | window.pluginWebUpdateNotice_.closeNotification | | close notification | | window.pluginWebUpdateNotice_.dismissUpdate | | dismiss current update and close notification,same behavior as dismiss button | | window.pluginWebUpdateNotice_.checkUpdate | | manual check update, a function wrap by debounce(5000ms) |
What was changed
Q&A
-
TypeScript intellisense, if you use window.pluginWebUpdateNotice_. or listener custom update event。
-
request version.json file get 404 error.
If you upload the production files bundled to cdn server:
Deploy the project in a non-root directory:
After version 1.2.0, in most case, you not need to set injectFileBase, it will be automatically detected from the base of vite config、publicPath of webpack config or publicPath of umi config
-
Custom notification button event.
-
Custom notification style.
you can cover css styles with higher weights. (default css file)
-
manual check update.
-
Some versions do not notify. For example, if the customer version is v1.0, you need to update to v1.0.1, but do not want to display the update prompt.
License
MIT
Description from the npm listing.
- @plugin-web-update-notification/vite
- vite
- vite-plugin
- web-update-notification
README badge
Show your rank in a README or on your website. The badge updates automatically.
Charts
Images: 30d · 1y · all time · 1600×900 dark
Adoption over time
7/30/90-day growth
Ranking history
Listing placement
Listing placement
Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.
Each band is one page of 20. Weekly downloads on a linear scale. Placement is projected from weekly downloads, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.
Recent observations
Full history (121)Similar npm Vite plugins plugins
All 20 @plugin-web-update-notification/vite alternativesData source
Weekly downloads (trailing 7 complete days) come from the official npm downloads API. Downloads include CI and mirrors and are not equivalent to installs or users. npm publishes no ratings.
Listing: https://www.npmjs.com/package/@plugin-web-update-notification/vite. First seen Oct 16, 2026; last successful collection Oct 19, 2026. See the methodology.