src/Fields/Field.php
public function getDataAttributes($extra = [])
    {
        $output = '';

        foreach (array_merge($this->html_attributes, $extra) as $attribute => $value) {
            if (! is_null($value)) {
                $output .= $attribute.'="'.$value.'"';
            } elseif (! $value && isset($this->args[Cuztom::uglify($attribute)])) {
                $output .= $attribute.'="'.$this->args[Cuztom::uglify($attribute)].'"';
            }
        }

        return apply_filters('cuztom_field_html_attributes', $output, $this, $extra);
    }
public function getDataAttributes($extra = [])
    {
        $output = '';

        foreach (array_merge($this->html_attributes, $extra) as $attribute => $value) {
            if (! is_null($value)) {
                $output .= $attribute.'="'.$value.'"';
            } elseif (! $value && isset($this->args[Cuztom::uglify($attribute)])) {
                $output .= $attribute.'="'.$this->args[Cuztom::uglify($attribute)].'"';
            }
        }

        return apply_filters('cuztom_field_html_attributes', $output, $this, $extra);
    }
public function getDataAttributes ( $ extra = [ ] ) { $ output = '' ; foreach ( array_merge ( $ this -> html_attributes , $ extra ) as $ attribute => $ value ) { if ( ! is_null ( $ value ) ) { $ output .= $ attribute . '="' . $ value . '"' ; } elseif ( ! $ value && isset ( $ this -> args [ Cuztom :: uglify ( $ attribute ) ] ) ) { $ output .= $ attribute . '="' . $ this -> args [ Cuztom :: uglify ( $ attribute ) ] . '"' ; } } return apply_filters ( 'cuztom_field_html_attributes' , $ output , $ this , $ extra ) ; }
Outputs the fields data attributes.

@param  array  $extra
@return string
Outputs the fields data attributes .