circular-dependency-plugin-async

1.0.6 • Public • Published

npm version

Circular Dependency Plugin Async

Detect modules with circular dependencies asynchronously when bundling with webpack.

Basic Usage

[!IMPORTANT]
Async mode doesn't fail the webpack build so if you want your build fail during production build set isAsync: false

// webpack.config.js
const CircularDependencyPluginAsync = require("circular-dependency-plugin-async");

module.exports = {
  plugins: [
    new CircularDependencyPlugin({
      // Path to the index file of your application
      indexFilePath: "./src/index.tsx",
      // Sync/async mode flag
      isAsync: true, // optional
      // Threshold for amount of circular dependecies to trigger the error
      threshold: 1, // optional
    }),
  ],
};

Package Sidebar

Install

npm i circular-dependency-plugin-async

Weekly Downloads

0

Version

1.0.6

License

MIT

Unpacked Size

7.64 kB

Total Files

6

Last publish

Collaborators

  • ignashevich