parcel-reporter-multiple-file-copier

1.0.7 • Public • Published

parcel-reporter-multiple-file-copier

npm version

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/"
    }
  ]
}

Package Sidebar

Install

npm i parcel-reporter-multiple-file-copier

Weekly Downloads

2

Version

1.0.7

License

MIT

Unpacked Size

4.26 kB

Total Files

8

Last publish

Collaborators

  • tiagotrindade