Gathering detailed insights and metrics for webpack-pwa-manifest
Gathering detailed insights and metrics for webpack-pwa-manifest
Gathering detailed insights and metrics for webpack-pwa-manifest
Gathering detailed insights and metrics for webpack-pwa-manifest
favicons-webpack-plugin
Let webpack generate all your favicons and icons for you
pwa-manifest-webpack-plugin
generating `manifest.json` for pwa app
@expo/webpack-pwa-manifest-plugin
Generates a progressive web app (PWA) manifest.json from a React Native app.json
webapp-webpack-plugin
Let webpack generate your progressive web app icons for you
Progressive Web App Manifest Generator for Webpack, with auto icon resizing and fingerprinting support.
npm install webpack-pwa-manifest
Typescript
Module System
Min. Node Version
Node Version
NPM Version
85.1
Supply Chain
88.5
Quality
75.9
Maintenance
50
Vulnerability
97.9
License
JavaScript (83.77%)
HTML (16.23%)
Total Downloads
16,472,967
Last Day
1,438
Last Week
42,859
Last Month
174,557
Last Year
2,369,361
514 Stars
171 Commits
93 Forks
8 Watching
12 Branches
19 Contributors
Minified
Minified + Gzipped
Latest Version
4.3.0
Package Id
webpack-pwa-manifest@4.3.0
Size
71.32 kB
NPM Version
6.14.4
Node Version
14.0.0
Publised On
17 Nov 2020
Cumulative downloads
Total Downloads
Last day
31.6%
1,438
Compared to previous day
Last week
-1.1%
42,859
Compared to previous week
Last month
-5.2%
174,557
Compared to previous month
Last year
-27%
2,369,361
Compared to previous year
Looking for people willing to help! More info
webpack-pwa-manifest
is a webpack plugin that generates a 'manifest.json' for your Progressive Web Application, with auto icon resizing and fingerprinting support.
If you are using inject
on your configuration, ensure that HtmlWebpackPlugin
appears before WebpackPwaManifest
in the plugins
array!
✔ Auto icon resizing
✔ Icon fingerprinting
✔ Manifest fingerprinting
✔ Auto manifest injection on HTML
✔ Hot Reload support
✔ ES6+ ready
1npm install --save-dev webpack-pwa-manifest
In your webpack.config.js
:
1// ES6+ 2import WebpackPwaManifest from 'webpack-pwa-manifest' 3 4// ES5 5var WebpackPwaManifest = require('webpack-pwa-manifest') 6 7... 8 9plugins: [ 10 new WebpackPwaManifest({ 11 name: 'My Progressive Web App', 12 short_name: 'MyPWA', 13 description: 'My awesome Progressive Web App!', 14 background_color: '#ffffff', 15 crossorigin: 'use-credentials', //can be null, use-credentials or anonymous 16 icons: [ 17 { 18 src: path.resolve('src/assets/icon.png'), 19 sizes: [96, 128, 192, 256, 384, 512] // multiple sizes 20 }, 21 { 22 src: path.resolve('src/assets/large-icon.png'), 23 size: '1024x1024' // you can also use the specifications pattern 24 }, 25 { 26 src: path.resolve('src/assets/maskable-icon.png'), 27 size: '1024x1024', 28 purpose: 'maskable' 29 } 30 ] 31 }) 32]
manifest.<fingerprint>.json
1{ 2 "name": "My Progressive Web App", 3 "orientation": "portrait", 4 "display": "standalone", 5 "start_url": ".", 6 "short_name": "MyPWA", 7 "description": "My awesome Progressive Web App!", 8 "background_color": "#ffffff", 9 "icons": [ 10 { 11 "src": "icon_1024x1024.<fingerprint>.png", 12 "sizes": "1024x1024", 13 "type": "image/png", 14 "purpose": "maskable" 15 }, 16 { 17 "src": "icon_1024x1024.<fingerprint>.png", 18 "sizes": "1024x1024", 19 "type": "image/png" 20 }, 21 { 22 "src": "icon_512x512.<fingerprint>.png", 23 "sizes": "512x512", 24 "type": "image/png" 25 }, 26 { 27 "src": "icon_384x384.<fingerprint>.png", 28 "sizes": "384x384", 29 "type": "image/png" 30 }, 31 { 32 "src": "icon_256x256.<fingerprint>.png", 33 "sizes": "256x256", 34 "type": "image/png" 35 }, 36 { 37 "src": "icon_192x192.<fingerprint>.png", 38 "sizes": "192x192", 39 "type": "image/png" 40 }, 41 { 42 "src": "icon_128x128.<fingerprint>.png", 43 "sizes": "128x128", 44 "type": "image/png" 45 }, 46 { 47 "src": "icon_96x96.<fingerprint>.png", 48 "sizes": "96x96", 49 "type": "image/png" 50 } 51 ] 52}
options
Type: object
You can follow the Web App Manifest specification.
The difference here is that, when defining icons, you can specify one icon with multiple sizes, using an array of integers, just as the example above.
You can also change the output's filename with the filename
property.
Presets of options
:
1{ 2 filename: "manifest.json", 3 name: "App", 4 orientation: "portrait", 5 display: "standalone", 6 start_url: ".", 7 crossorigin: null, 8 inject: true, 9 fingerprints: true, 10 ios: false, 11 publicPath: null, 12 includeDirectory: true 13}
By default, HTML injection and fingerprint generation are on.
With inject: false
and fingerprints: false
, respectively, you can turn them off.
If inject: true
and 'theme-color'
property is not defined, it wil try to use theme_color
as default. Otherwise, no theme-color
meta tag will be injected.
With includeDirectory: true
, we will use filename
's directory to export the manifest file.
With orientation: 'omit'
, the orientation key will be omitted from the generated manifest file.
When inject: true
and ios: true
, specific Apple meta tags will be injected to the HTML code when possible, as requested at issue #13. You can see Apple's Configuring Web Application for more information. Instead of using a boolean value, you can also use an object to specify certain link or meta tag, for instance:
1 ... 2 ios: { 3 'apple-mobile-web-app-title': 'AppTitle', 4 'apple-mobile-web-app-status-bar-style': 'black' 5 }
If publicPath
option is not given, this plugin fallbacks to Webpack's public path definition.
When defining an icon object, you can also specify its output directory using a property called destination
. Using ios: true
in an icon object makes it eligible to the apple-touch-icon
meta tag injection. Using ios: 'startup'
in an icon object makes it eligible to the apple-touch-startup-image
meta tag injection.
1 ... 2 icons: [ 3 { 4 src: path.resolve('src/assets/icons/ios-icon.png'), 5 sizes: [120, 152, 167, 180, 1024], 6 destination: path.join('icons', 'ios'), 7 ios: true 8 }, 9 { 10 src: path.resolve('src/assets/icons/ios-icon.png'), 11 size: 1024, 12 destination: path.join('icons', 'ios'), 13 ios: 'startup' 14 }, 15 { 16 src: path.resolve('src/assets/icons/android-icon.png'), 17 sizes: [36, 48, 72, 96, 144, 192, 512], 18 destination: path.join('icons', 'android') 19 } 20 ] 21}
If you specify a valid crossorigin
property it will be added to the <link rel="manifest">
in the HTML document.
This property determines if the request for the manifest includes CORS headers and is required if the manifest is located on a different domain or requires authentication.
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
Found 7/18 approved changesets -- score normalized to 3
Reason
project is archived
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
28 existing vulnerabilities detected
Details
Score
Last Scanned on 2024-12-16
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More