webpack/webpack-cli

View on GitHub
packages/create-webpack-app/src/utils/pkgInstallAction.ts

Summary

Maintainability
A
2 hrs
Test Coverage

Function default has 45 lines of code (exceeds 25 allowed). Consider refactoring.
Open

export default async function (plop: NodePlopAPI) {
  plop.setPlopfilePath(resolve(__dirname, "../plopfile.js"));
  plop.setDefaultInclude({ actions: true });
  plop.setActionType("pkgInstall", (answers, config) => {
    const options: SpawnOptionsWithStdioTuple<
Severity: Minor
Found in packages/create-webpack-app/src/utils/pkgInstallAction.ts - About 1 hr to fix

    Function returnPromise has 26 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        const returnPromise: Promise<string> = new Promise((resolve, reject) => {
          const returnMessage = `Project Dependencies installed successfully`;
          const packageManager = answers.packageManager;
          const packages = config.packages.length == 1 ? [config.packages[0]] : config.packages;
          const installOptions: Record<string, Array<string>> = {
    Severity: Minor
    Found in packages/create-webpack-app/src/utils/pkgInstallAction.ts - About 1 hr to fix

      There are no issues that match your filters.

      Category
      Status