differ

package
v0.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 30, 2026 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package differ turns a single attribute's before/after values into an ordered list of render variants (preferred → minimal). All value-type knowledge lives here; fit and render treat the result generically.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Diff

func Diff(in Input) model.Field

Diff builds the ordered variant ladder for one attribute.

Types

type Input

type Input struct {
	ResourceType string
	Attr         string
	Before       any
	After        any
	Sensitive    bool
	Unknown      bool
	ForceDiffer  string // "" | auto | structural | json | yaml | line | summary | hide
	MaxLines     int    // 0 = no cap
	NoDetect     bool   // when true, skip type sniffing for string values (force line diff)
}

Input is everything Diff needs for one attribute.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL