Varie Bundler

3.0.4 · active · verified Sun Apr 19

Varie Bundler, currently at stable version 3.0.4, provides a pre-configured and extensible Webpack setup specifically tailored for Varie framework applications. It abstracts away complex Webpack configurations, offering a fluent API to define common bundling concerns such as web/service workers, proxy URLs, custom Webpack plugins, file copying, and aggressive code splitting. While its explicit release cadence is not publicly documented, the project has undergone significant updates, moving from early 0.x versions to its current 3.x iteration, indicating active development. A key differentiator is its deep integration with the Varie ecosystem, making it an opinionated but highly efficient choice for developers working within that framework, rather than a general-purpose Webpack utility for any JavaScript project.

Common errors

Warnings

Install

Imports

Quickstart

Demonstrates how to initialize the Varie Bundler within a Varie application's configuration file (`varie.js`) and apply common configurations like file copying, web worker support, proxy setup, aggressive code splitting, and adding a custom webpack plugin.

const { Bundler } = require('varie-bundler');

module.exports = {
  // ... potentially other Varie configuration properties
  bundler: new Bundler()
    .copy([
      { from: './resources/assets/images', to: './dist/images' },
      { from: './public/manifest.json', to: './dist/manifest.json' }
    ])
    .webWorkers() // Enable web worker support
    .proxy('http://localhost:8080') // Set up a proxy server
    .aggressiveSplitting() // Optimize chunk splitting
    .plugin('webpackbar', require('webpackbar')) // Add a custom webpack plugin
    .dontClean(['.gitkeep'])
};

view raw JSON →