Gathering detailed insights and metrics for vue-pwa-asset-generator
Gathering detailed insights and metrics for vue-pwa-asset-generator
Gathering detailed insights and metrics for vue-pwa-asset-generator
Gathering detailed insights and metrics for vue-pwa-asset-generator
pwa-asset-generator
Automates PWA asset generation and image declaration. Automatically generates icon and splash screen images, favicons and mstile images. Updates manifest.json and index.html files with the generated images according to Web App Manifest specs and Apple Hum
@vite-pwa/assets-generator
Zero-config PWA Assets Generator
vite-plugin-pwa
Zero-config PWA for Vite
@vite-pwa/nuxt
Zero-config PWA for Nuxt 3
npm install vue-pwa-asset-generator
Module System
Min. Node Version
Typescript Support
Node Version
NPM Version
176 Stars
88 Commits
6 Forks
3 Watching
2 Branches
2 Contributors
Updated on 21 Nov 2024
JavaScript (100%)
Cumulative downloads
Total Downloads
Last day
-38.8%
60
Compared to previous day
Last week
-39.5%
201
Compared to previous week
Last month
0%
1,092
Compared to previous month
Last year
18.7%
13,918
Compared to previous year
TLDR:
1npx vue-pwa-asset-generator -a {512x512_png_source | svg_source} [-o {output_folder} [-b {fallback background color}]]
This package creates for you all the default assets used in a VueJS app with PWA plugin as well as a manifest JSON with the icons
attribute set.
You can use npx as shown above or you can install it globally:
1npm install --global vue-pwa-asset-generator
or
1yarn global add vue-pwa-asset-generator
or
1pnpm global add vue-pwa-asset-generator
VueJS PWA asset generator has a vue-asset-generate
command with two parameters:
-a
: input asset, it can be an SVG file or a PNG file (the largest image is a 512x512 png image).-o
: output folder (created if it does not exist). This parameter is optional, by default, vue-pwa-asset-generator
will assume the command is run in a VueJS project. Therefor the manifest.json
and favicon.ico
are in public
folder, the rest ies in public/img/icons
folder.-b
: fallback background color for the ico
image.--no-manifest
: option to not generate manifest.json filevue-asset-generate -a logo.png -o img
vue-asset-generate -a logo.svg
vue-asset-generate -a logo.svg -o img
vue-asset-generate -a logo.svg -o img -b 182C61
vue-asset-generate -a logo.svg -o img -b "#9AECDB"
You can configure your PWA with the vue.config.js
file.
Here an example of how you can merge the created manifest.json
and your configuration file:
1module.exports = { 2 // ... other configurations 3 pwa: { 4 themeColor: "#130f40", 5 msTileColor: "#130f40", 6 name: "My app", 7 manifestOptions: { 8 icons: [ 9 { 10 src: "./img/icons/android-chrome-192x192.png", 11 sizes: "192x192", 12 type: "image/png", 13 }, 14 { 15 src: "./img/icons/android-chrome-512x512.png", 16 sizes: "512x512", 17 type: "image/png", 18 }, 19 { 20 src: "./img/icons/android-chrome-maskable-192x192.png", 21 sizes: "192x192", 22 type: "image/png", 23 purpose: "maskable", 24 }, 25 { 26 src: "./img/icons/android-chrome-maskable-512x512.png", 27 sizes: "512x512", 28 type: "image/png", 29 purpose: "maskable", 30 }, 31 { 32 src: "./img/icons/apple-touch-icon-60x60.png", 33 sizes: "60x60", 34 type: "image/png", 35 }, 36 { 37 src: "./img/icons/apple-touch-icon-76x76.png", 38 sizes: "76x76", 39 type: "image/png", 40 }, 41 { 42 src: "./img/icons/apple-touch-icon-120x120.png", 43 sizes: "120x120", 44 type: "image/png", 45 }, 46 { 47 src: "./img/icons/apple-touch-icon-152x152.png", 48 sizes: "152x152", 49 type: "image/png", 50 }, 51 { 52 src: "./img/icons/apple-touch-icon-180x180.png", 53 sizes: "180x180", 54 type: "image/png", 55 }, 56 { 57 src: "./img/icons/apple-touch-icon.png", 58 sizes: "180x180", 59 type: "image/png", 60 }, 61 { 62 src: "./img/icons/favicon-16x16.png", 63 sizes: "16x16", 64 type: "image/png", 65 }, 66 { 67 src: "./img/icons/favicon-32x32.png", 68 sizes: "32x32", 69 type: "image/png", 70 }, 71 { 72 src: "./img/icons/msapplication-icon-144x144.png", 73 sizes: "144x144", 74 type: "image/png", 75 }, 76 { 77 src: "./img/icons/mstile-150x150.png", 78 sizes: "150x150", 79 type: "image/png", 80 }, 81 ], 82 }, 83 }, 84};
When generating assets from a png file, the generator creates a black and white svg for the safari-pinned-tab.svg
icon, some manual modifications may be necessary.
I hope this will be useful as it is for me! ♥
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
SAST tool detected but not run on all commits
Details
Reason
security policy file detected
Details
Reason
Found 1/21 approved changesets -- score normalized to 0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
project is not fuzzed
Details
Reason
license file not detected
Details
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
19 existing vulnerabilities detected
Details
Score
Last Scanned on 2024-11-18
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