Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

rollup-plugin-copy-assets

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rollup-plugin-copy-assets

Copy additional assets into the output directory of your rollup bundle.

  • 1.0.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

rollup-plugin-copy-assets

build status npm version

Copy additional assets into the output directory of your rollup bundle.

Installation

npm install --save-dev rollup-plugin-copy-assets

Usage

// rollup.config.js
import copy from 'rollup-plugin-copy-assets';

export default {
  entry: 'src/index.js',
  dest: 'dist/bundle.js',
  plugins: [
    copy({
      assets: [
        './src/assets',
        './src/external/buffer.bin',
      ],
    }),
  ],
};

On final bundle generation the provided files will be copied over into the output folder of your rollup bundle.

# Source directory structure
src/
- index.js
- assets/
  - some-library-needing-special-treatment.js
- external/
  - buffer.bin

# Output directory structure
dist/
- bundle.js
- assets/
  - some-library-needing-special-treatment.js
- external/
  - buffer.bin

Options

  • assets: (required) An array of paths to copy. Accepts files as well as directories.

License

MIT

Keywords

FAQs

Package last updated on 22 Mar 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc