// GetAttributes returns a list of Attributer values that this tag has.
//
// Any Class, Style values are returned here as Attribute values.
GetAttributes returns a list of Attributer values that this tag has.

Any Class, Style values are returned here as Attribute values.
// GetAttributes returns a list of Attributer values that this tag has . // // Any Class Style values are returned here as Attribute values .
func (t *Tag) GetAttributes() []Attributer {
	attrs := t.attributes
	if len(t.cssOrder) != 0 {
		attrs = append(attrs, NewAttribute("class", strings.Join(t.cssOrder, " ")))
	}
	if len(t.styleOrder) != 0 {
		value := ""
		for i := 0; i < len(t.styleOrder); i++ {
			name := t.styleOrder[i]
			if t.styleValues[name] == nil {
				continue
			}
			value += name + ":" + *t.styleValues[name] + ";"
		}
		attrs = append(attrs, NewAttribute("style", value))
	}
	return attrs
}
func ( t * Tag ) GetAttributes ( ) [ ] Attributer { attrs := t . attributes if len ( t . cssOrder ) != 0 { attrs = append ( attrs , NewAttribute ( " " , strings . Join ( t . cssOrder , " " ) ) ) } if len ( t . styleOrder ) != 0 { value := " " for i := 0 ; i < len ( t . styleOrder ) ; i ++ { name := t . styleOrder [ i ] if t . styleValues [ name ] == nil { continue } value += name + " " + * t . styleValues [ name ] + " " } attrs = append ( attrs , NewAttribute ( " " , value ) ) } return attrs }
GetAttributes returns a list of Attributer values that this tag has.
GetAttributes returns a list of Attributer values that this tag has .