@intrnl/rollup-plugin-include
TypeScript icon, indicating that this package has built-in type declarations

0.1.2 • Public • Published

rollup-plugin-include

Include chunks or assets within your Rollup bundle

Usage

npm install --save-dev @intrnl/rollup-plugin-include
# pnpm install --save-dev @intrnl/rollup-plugin-include
# yarn add --dev @intrnl/rollup-plugin-include
// rollup.config.js
import { include as includePlugin } from '@intrnl/rollup-plugin-include';

export default {
  input: 'src/index.js',
  plugins: [
    includePlugin(),
  ],
};
// Reference any file and it will be included within your Rollup bundle
let image_src = new URL('./assets/image.png', import.meta.url);

// Any files ending with .js will be picked up as a chunk by default,
// making it usable as a module worker.
let worker_src = new URL('./worker.js', import.meta.url);

Readme

Keywords

none

Package Sidebar

Install

npm i @intrnl/rollup-plugin-include

Weekly Downloads

0

Version

0.1.2

License

MIT

Unpacked Size

12.2 kB

Total Files

6

Last publish

Collaborators

  • intrnl