parcel-reporter-multiple-file-copier
v1.0.7
Published
Parcel v2 plugin for copying multiple static files
Downloads
13
Maintainers
Readme
parcel-reporter-multiple-file-copier
This is a Parcel v2 plugin for copying multiple static files.
Forked from this plugin.
Install
Yarn
$ yarn add -D parcel-reporter-multiple-file-copier
NPM
$ npm install parcel-reporter-multiple-file-copier --save-dev
Usage
Configuration is set under staticFiles
in package.json
. It must be an array of objects containing origin
and destination
props:
| Property | Path | | -------------|----------------------------------------- | | origin | Example: node_modules/@package/public | | destination | Example: public |
You ⚠️ must extend Parcel configuration with the plugin name in .parcelrc
:
{
"reporters": [
"...",
"parcel-reporter-multiple-file-copier"
]
}
*Note that the "..." notation is used to keep the default report plugins loaded by Parcel.
Example
This example will copy the contents of the folder public into the folder DIST_DIR_PATH/public. (Note that the DIST_DIR_PATH is specified by Parcel, you don't need to pass it)
package.json
{
"staticFiles": [
{
"origin": "public",
"destination": "public/"
}
]
}