Skip to content

add support for struct field tags#51

Open
aerth wants to merge 1 commit into
kr:masterfrom
aerth:master
Open

add support for struct field tags#51
aerth wants to merge 1 commit into
kr:masterfrom
aerth:master

Conversation

@aerth
Copy link
Copy Markdown

@aerth aerth commented Dec 17, 2017

With these changes, one can add a struct field tag pretty:"-" to ignore pretty printing a particular field.

For example, the "z" field would not be pretty printed in the following struct

type testFieldTag struct {
	x, y int
	z string `pretty:"-"`
}

Now print long embedded structs prettier

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants