![PyPI Now Supports iOS and Android Wheels for Mobile Python Development](https://cdn.sanity.io/images/cgdhsj6q/production/96416c872705517a6a65ad9646ce3e7caef623a0-1024x1024.webp?w=400&fit=max&auto=format)
Security News
PyPI Now Supports iOS and Android Wheels for Mobile Python Development
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
vue-cli-plugin-unipwa
Advanced tools
pwa plugin for vue-cli
The service worker added with this plugin is only enabled in the production environment (e.g. only if you run npm run build
or yarn build
). Enabling service worker in a development mode is not a recommended practice, because it can lead to the situation when previously cached assets are used and the latest local changes are not included.
Instead, in the development mode the noopServiceWorker.js
is included. This service worker file is effectively a 'no-op' that will reset any previous service worker registered for the same host:port combination.
If you need to test a service worker locally, build the application and run a simple HTTP-server from your build directory. It's recommended to use a browser incognito window to avoid complications with your browser cache.
Configuration is handled via the pwa
property of either the vue.config.js
file, or the "vue"
field in package.json
.
pwa.workboxPluginMode
This allows you to choose between the two modes supported by the underlying
workbox-webpack-plugin
.
'GenerateSW'
(default), will lead to a new service worker file being created
each time you rebuild your web app.
'InjectManifest'
allows you to start with an existing service worker file,
and creates a copy of that file with a "precache manifest" injected into it.
The "Which Plugin to Use?" guide can help you choose between the two modes.
pwa.workboxOptions
These options are passed on through to the underlying workbox-webpack-plugin
.
For more information on what values are supported, please see the guide for
GenerateSW
or for InjectManifest
.
pwa.name
Default: "name" field in package.json
Used as the value for the apple-mobile-web-app-title
meta tag in the generated HTML. Note you will need to edit public/manifest.json
to match this.
pwa.themeColor
'#4DBA87'
pwa.msTileColor
'#000000'
pwa.appleMobileWebAppCapable
Default: 'no'
This defaults to 'no'
because iOS before 11.3 does not have proper PWA support. See this article for more details.
pwa.appleMobileWebAppStatusBarStyle
'default'
pwa.assetsVersion
Default: ''
This option is used if you need to add a version to your icons and manifest, against browser’s cache. This will append ?v=<pwa.assetsVersion>
to the URLs of the icons and manifest.
pwa.manifestPath
Default: 'manifest.json'
The path of app’s manifest. If the path is an URL, the plugin won't generate a manifest.json in the dist directory during the build.
pwa.manifestOptions
Default: {}
The object will be used to generate the manifest.json
If the following attributes are not defined in the object, the options of pwa
or default options will be used instead.
pwa.name
pwa.name
'.'
'standalone'
pwa.themeColor
pwa.manifestCrossorigin
Default: undefined
Value for crossorigin
attribute in manifest link tag in the generated HTML. You may need to set this if your PWA is behind an authenticated proxy. See cross-origin values for more details.
pwa.iconPaths
Defaults:
{
favicon32: 'img/icons/favicon-32x32.png',
favicon16: 'img/icons/favicon-16x16.png',
appleTouchIcon: 'img/icons/apple-touch-icon-152x152.png',
maskIcon: 'img/icons/safari-pinned-tab.svg',
msTileImage: 'img/icons/msapplication-icon-144x144.png'
}
Change these values to use different paths for your icons. As of v4.3.0, you can use null
as a value and that icon will not be included.
// Inside vue.config.js
module.exports = {
// ...other vue-cli plugin options...
pwa: {
name: 'My App',
themeColor: '#4DBA87',
msTileColor: '#000000',
appleMobileWebAppCapable: 'yes',
appleMobileWebAppStatusBarStyle: 'black',
// configure the workbox plugin
workboxPluginMode: 'InjectManifest',
workboxOptions: {
// swSrc is required in InjectManifest mode.
swSrc: 'dev/sw.js',
// ...other Workbox options...
}
}
}
vue add pwa
config.plugin('workbox')
5.0.4 (2022-03-22)
@vue/cli-service
publicPath: 'auto'
(@AndreiSoroka)@vue/cli-shared-utils
, @vue/cli-ui
node-ipc
with @achrinza/node-ipc
to further secure the dependency chainFAQs
pwa plugin for vue-cli
The npm package vue-cli-plugin-unipwa receives a total of 7 weekly downloads. As such, vue-cli-plugin-unipwa popularity was classified as not popular.
We found that vue-cli-plugin-unipwa demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.