1.1.0 • Published 2 years ago

eval-webpack-plugin v1.1.0

Weekly downloads
1
License
MIT
Repository
-
Last release
2 years ago

Eval Webpack Plugin

Create an in-memory webpack module by evaluating a function.

This plugin will re-run the function on a configurable pollInterval, invalidating the compilation and triggering a reload if the return value has changed.

The return value must be JSON-stringifyable.

Example

const EvalWebpackPlugin = require("eval-webpack-plugin");

// ...

plugins: [
  EvalWebpackPlugin("./example.js", () => 42),
  // We can then write require("./example.js") to access the value 42
];

// ...

Related