Member Junction
    Preparing search index...

    Interface DeepDiffConfig

    Configuration options for deep diff generation

    interface DeepDiffConfig {
        includeArrayIndices: boolean;
        includeUnchanged: boolean;
        maxDepth: number;
        maxStringLength: number;
        treatNullAsUndefined: boolean;
        valueFormatter?: (value: any, type: string) => string;
    }
    Index

    Properties

    includeArrayIndices: boolean

    Whether to include array indices in paths (e.g., "items[0]" vs "items"). Provides more precise change tracking for arrays.

    true
    
    includeUnchanged: boolean

    Whether to include unchanged paths in the diff results. Useful for seeing the complete structure comparison.

    false
    
    maxDepth: number

    Maximum depth to traverse in nested objects. Prevents infinite recursion and controls performance.

    10
    
    maxStringLength: number

    Maximum string length before truncation in formatted output. Helps keep the output readable for large text values.

    100
    
    treatNullAsUndefined: boolean

    Whether to treat null values as equivalent to undefined. When true, transitions between null and undefined are not considered changes, and null values in the old object are treated as "not present" for new values. Useful for APIs where null and undefined are used interchangeably.

    false
    
    valueFormatter?: (value: any, type: string) => string

    Custom value formatter for the formatted output. Allows customization of how values are displayed.

    Type Declaration

      • (value: any, type: string): string
      • Parameters

        • value: any

          The value to format

        • type: string

          The type of the value

        Returns string

        Formatted string representation