JSPM

circular-dependency-plugin-async

1.0.6
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 7
  • Score
    100M100P100Q44497F
  • License MIT

Detect modules with circular dependencies asynchronously when bundling with webpack.

Package Exports

  • circular-dependency-plugin-async
  • circular-dependency-plugin-async/index.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (circular-dependency-plugin-async) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

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
    }),
  ],
};