{"library":"metalsmith-rollup","title":"metalsmith-rollup","description":"A Metalsmith plugin that bundles JavaScript files using Rollup. Version 2.0.0 is current; it supports source maps and can ignore processed source files. This plugin is designed for Metalsmith build pipelines where you need to bundle ES modules with Rollup. It only supports the JavaScript API; CLI usage with metalsmith.json is not yet available. The main differentiator is its tight integration with Metalsmith's build process, allowing seamless inclusion of bundled output inside the build directory.","language":"javascript","status":"active","last_verified":"Mon Apr 27","install":{"commands":["npm install metalsmith-rollup"],"cli":null},"imports":["const rollup = require('metalsmith-rollup')","const rollup = require('metalsmith-rollup')","import type { Plugin } from 'metalsmith-rollup' // TypeScript only"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"const Metalsmith = require('metalsmith');\nconst rollup = require('metalsmith-rollup');\n\nMetalsmith(__dirname)\n  .use(rollup({\n    input: 'src/js/main.js',\n    output: {\n      dest: 'js/bundle.js'\n    }\n  }))\n  .build((err) => {\n    if (err) throw err;\n    console.log('Build complete');\n  });","lang":"javascript","description":"Shows how to use the plugin with Metalsmith to bundle a JavaScript entry point into a single output file.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}