V2 Migration
New Options
update
: control the update logic of SW"disabled"
: Do nothing even when new service worker is available. After new service work succeeds installing and starts waiting, it will control page and provide new content in next visit."available"
: Only display update popup when the new service worker is available"hint"
: Display a hint to let user choose to refresh immediately"force"
: unregister current service worker immediately then refresh to get new content
appendBase
: automatically insertbase
to themanifest
optionhintComponent
: Hint component for detecting new contentshouldPrefetch hint: Now the plugin will check
shouldPrefetch
option in config file and warn you to disable it.
Changed Options
cacheHTML
default value changed fromtrue
tofalse
This can effectively reduce the SW update time
popupComponent
renamed toupdateComponent
This is because we added a new prompt popup window, so we need to avoid name confusion