From bbc5325760de27d634b7118542be01e56cf0a944 Mon Sep 17 00:00:00 2001 From: Aaron Ackerman Date: Mon, 28 Aug 2017 21:39:18 -0500 Subject: [PATCH] Added README documentation for parameter in onDetected --- README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 02cb46b..267f1c4 100644 --- a/README.md +++ b/README.md @@ -20,8 +20,9 @@ module.exports = { failOnError: true, // override `exclude` and `failOnError` behavior // `onDetected` is called for each module that is cyclical - onDetected({ paths, compilation }) { + onDetected({ module: webpackModuleRecord, paths, compilation }) { // `paths` will be an Array of the relative module paths that make up the cycle + // `module` will be the module record generated by webpack that caused the cycle compilation.errors.push(new Error(paths.join(' -> '))) } })