You are here

public function MiconIcon::setAttribute in Micon 8

Same name and namespace in other branches
  1. 2.x src/MiconIcon.php \Drupal\micon\MiconIcon::setAttribute()

Sets values for an attribute key.

Parameters

string $attribute: Name of the attribute.

string|array $value: Value(s) to set for the given attribute key.

Return value

$this

Overrides MiconIconInterface::setAttribute

File

src/MiconIcon.php, line 150

Class

MiconIcon
Defines the Micon icon.

Namespace

Drupal\micon

Code

public function setAttribute($attribute, $value) {
  $this->attributes
    ->setAttribute($attribute, $value);
  return $this;
}