Angular Modernizer
    Preparing search index...

    Result from the analyze-core-to-shared tool.

    interface AnalyzeCoreToSharedResult {
        counts: {
            affectedCoreFiles: number;
            analyzedFiles: number;
            bySeverity: Record<string, number>;
            totalViolations: number;
            uniqueSharedModules: number;
        };
        metadata: {
            duration: number;
            impactAssessmentEnabled: boolean;
            projectRoot: string;
        };
        summary: string;
        violations: {
            filePath: string;
            id: string;
            impactAssessment?: {
                breakingChangeRisk: "LOW"
                | "MEDIUM"
                | "HIGH";
                reverseDependencies: { file: string; imports: string[] }[];
                riskFactors: string[];
                transitiveDependencies: string[];
            };
            importedItem: string;
            importedModule: string;
            line: number;
            message: string;
            metadata?: Record<string, unknown>;
            severity: "error" | "warning";
            suggestedFix: string;
        }[];
    }
    Index

    Properties

    counts: {
        affectedCoreFiles: number;
        analyzedFiles: number;
        bySeverity: Record<string, number>;
        totalViolations: number;
        uniqueSharedModules: number;
    }

    Counts over all violations.

    Type Declaration

    • affectedCoreFiles: number

      Core files with at least one violation.

    • analyzedFiles: number

      Number of analyzed core files.

    • bySeverity: Record<string, number>

      Violations per severity.

    • totalViolations: number

      Number of all violations.

    • uniqueSharedModules: number

      Distinct shared modules imported.

    metadata: {
        duration: number;
        impactAssessmentEnabled: boolean;
        projectRoot: string;
    }

    Analysis metadata.

    Type Declaration

    • duration: number

      Duration of the analysis in milliseconds.

    • impactAssessmentEnabled: boolean

      Whether the impact assessment ran.

    • projectRoot: string

      Root path of the analyzed project.

    summary: string

    Human-readable summary for LLM consumption.

    violations: {
        filePath: string;
        id: string;
        impactAssessment?: {
            breakingChangeRisk: "LOW" | "MEDIUM" | "HIGH";
            reverseDependencies: { file: string; imports: string[] }[];
            riskFactors: string[];
            transitiveDependencies: string[];
        };
        importedItem: string;
        importedModule: string;
        line: number;
        message: string;
        metadata?: Record<string, unknown>;
        severity: "error" | "warning";
        suggestedFix: string;
    }[]

    Core-to-shared violations found.

    Type Declaration

    • filePath: string

      Core file that imports from the shared layer.

    • id: string

      Violation id: <filePath>:<line>:<importedModule>:<importedItem>.

    • OptionalimpactAssessment?: {
          breakingChangeRisk: "LOW" | "MEDIUM" | "HIGH";
          reverseDependencies: { file: string; imports: string[] }[];
          riskFactors: string[];
          transitiveDependencies: string[];
      }

      Impact of changing the import; only with includeImpactAssessment.

      • breakingChangeRisk: "LOW" | "MEDIUM" | "HIGH"

        Risk of a breaking change, derived from the reverse dependencies.

      • reverseDependencies: { file: string; imports: string[] }[]

        Files under src/ that import the core file.

      • riskFactors: string[]

        Reasons for the risk level.

      • transitiveDependencies: string[]

        Non-relative imports of the core file, without @angular and @shared modules.

    • importedItem: string

      Imported name, with as <alias> when aliased.

    • importedModule: string

      Module specifier of the shared module.

    • line: number

      Line of the import declaration.

    • message: string

      Violation message.

    • Optionalmetadata?: Record<string, unknown>

      Violation type and the imported name and alias.

    • severity: "error" | "warning"

      error without impact assessment or with HIGH risk, warning with MEDIUM or LOW risk.

    • suggestedFix: string

      Suggested refactoring.