Releases: guMcrey/version-rocket
1.7.1
English
What's Changed
#35 (Thank you for the suggestion, fickleness-youth)
💄 Optimization: The fetch request parameter for real-time checking of updates in a specified file address's content can be enhanced by adding {method: "HEAD", cache: "no-cache"}
. This configuration instructs the server to only return the response headers without the actual response body, allowing for faster retrieval of ETag or Last-Modified information.
Full Changelog: v1.7.0...v1.7.1
简体中文
有哪些更改?
#35 (感谢 fickleness-youth 同学的建议)
💄 优化: Web 应用版本实时检测方法指定文件地址内容是否有更新的 fetch 请求参数, 通过添加 {method: "HEAD", cache: "no-cache"}
来让服务器将只返回响应头信息而不返回实际的响应体,因此可以更快地获取到 ETag 或 Last-Modified 等响应头信息
更新日志: v1.7.0...v1.7.1
1.7.0
English
V1.7.0
is here 🎉! This version introduces a new way of real-time version detection for web applications. In addition to managing version numbers, it is now possible to detect version changes by checking the content of specified files. You can pass an array of one or more specified file addresses and choose a mode to check these files.
When a change is detected in one or more of the specified files, a new version prompt will be displayed to notify users of a new version release.
The advantage of this method is that it does not require maintaining a version.json file to achieve real-time version management. Compared to managing version numbers, this method is simpler and more convenient.
The disadvantage of this method is that it does not support maintaining "modification details of the current version or other information that needs to be displayed in the prompt window". (If this is required, it is recommended to use the "version number management" method.)
What's Changed
New configuration options have been added in this version:
- 🆕
checkOriginSpecifiedFilesUrl
: a list of file addresses to be monitored. - 🆕
checkOriginSpecifiedFilesUrlMode
: supports two modes 'one' | 'all' to be used with checkOriginSpecifiedFilesUrl (default 'one'). - 🆕
enable
: a configuration option to enable/disable version monitoring (default true). - 🆕
clearIntervalOnDialog
: a configuration option to clear the interval timer after the new version prompt dialog is displayed (default false)
Full Changelog: v1.6.7...v1.7.0
简体中文
V1.7.0
来了 🎉! 该版本新增了另一种实时检测 Web 应用版本的方式,即除了管理版本号外,还可以通过检测指定文件内容是否有更新来管理版本。您可以传入一个或多个指定文件地址,并选择检测指定文件的模式。
当检测到指定文件列表中的一个或多个文件发生更改时,将会显示一个新版本提示框,以通知用户有新版本发布。
该方式的优点是:无需维护 version.json 文件即可实现实时版本管理,与管理版本号的方式相比更加简单方便。
该方式的缺点是:不支持维护“当前版本的修改内容或其他需要显示在提示弹窗上的内容”。(如有该需求, 建议使用“管理版本号”的方式)
有哪些更改?
- 🆕 新增
checkOriginSpecifiedFilesUrl
配置项: 希望监测的远程文件地址列表 - 🆕 新增
checkOriginSpecifiedFilesUrlMode
配置项: 支持两种模式 'one' | 'all', 与checkOriginSpecifiedFilesUrl
配合使用 (默认 'one') - 🆕 新增
enable
配置项: 是否启用版本监测 (默认 true) - 🆕 新增
clearIntervalOnDialog
配置项: 新版本提示弹窗出现后, 是否清空定时器 (默认 false)
更新日志: v1.6.7...v1.7.0