Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/azerella/rollup-plugin-manifest-json
Rollup plugin to generate a manifest.json file used to tell the browser about your web app.
https://github.com/azerella/rollup-plugin-manifest-json
manifest-json nodejs npm-module rollup-plugin
Last synced: about 1 month ago
JSON representation
Rollup plugin to generate a manifest.json file used to tell the browser about your web app.
- Host: GitHub
- URL: https://github.com/azerella/rollup-plugin-manifest-json
- Owner: azerella
- License: mit
- Created: 2019-11-22T04:09:56.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2022-09-02T02:43:43.000Z (over 2 years ago)
- Last Synced: 2024-05-18T20:42:33.917Z (7 months ago)
- Topics: manifest-json, nodejs, npm-module, rollup-plugin
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/rollup-plugin-manifest-json
- Size: 422 KB
- Stars: 13
- Watchers: 1
- Forks: 3
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
- awesome - manifest-json - Generate a `manifest.json` file for a PWA. (Plugins / Output)
README
# rollup-plugin-manifest-json
[![CI](https://github.com/azerella/rollup-plugin-manifest-json/actions/workflows/CI.yml/badge.svg)](https://github.com/azerella/rollup-plugin-manifest-json/actions/workflows/CI.yml)
Rollup plugin that generates a [web application manifest](https://w3c.github.io/manifest/#using-a-link-element-to-link-to-a-manifest) file. This file contains the startup parameters and application defaults when a web application is launched.
## Install
```sh
# NPM
npm i --save-dev rollup-plugin-manifest-json# Yarn
yarn add -D rollup-plugin-manifest-json
```## Usage
```js
import manifestJSON from "rollup-plugin-manifest-json";export default {
input: "main.js",
plugins: [
...
manifestJSON({
input: "public/manifest.json", // Required
// minify: true
// output: "public/manifest.webmanifest"
manifest: {
short_name: "different-short-name"
}
})
]
}
```## Options
### input
**Required**
Type: `string`
Default: `""`
The web application manifest file location that will be either cloned or modified and moved into the Rollup build directory.
### minify
_Optional_
Type: `boolean`
Default: `true`
Whether or not to mangle the output file, it's recommended to minify the file as it will reduce the file size.
### manifest
_Optional_
Type: `object`
Default: `{}`
The key values you wish to add or modify given the existing web application manifest file. For a full list of key values to use [see here.](https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/manifest.json)
### output
_Optional_
Type: `string`
Default: `public/manifest.json`
Output directory to write the manifest file to, useful for building your app outside of the root rollup folder.
## Contributors
Don't be scared to raise an issue or a pull request!
Any contributions, no matter how big or small will land your picture here and be greatly appreciated ❤️
[npm-version-badge]:https://img.shields.io/npm/v/rollup-plugin-manifest-json