func (f *Formatter) Marshal(v interface{}) ([]byte, error) {
	data, err := json.Marshal(v)
	if err != nil {
		return nil, err
	}

	if !f.DisablePretty {
		data, err = f.format(data)
	}

	return data, err
}
// Marshal marshals and formats JSON data.
Marshal marshals and formats JSON data.
// Marshal marshals and formats JSON data .
func (f *Formatter) Marshal(v interface{}) ([]byte, error) {
	data, err := json.Marshal(v)
	if err != nil {
		return nil, err
	}
	if !f.DisablePretty {
		data, err = f.format(data)
	}
	return data, err
}
func ( f * Formatter ) Marshal ( v interface { } ) ( [ ] byte , error ) { data , err := json . Marshal ( v ) if err != nil { return nil , err } if ! f . DisablePretty { data , err = f . format ( data ) } return data , err }
Marshal marshals and formats JSON data.
Marshal marshals and formats JSON data .