1
0
Fork 0
mirror of https://github.com/archtechx/laravel-seo.git synced 2025-12-12 18:04:03 +00:00

set custom favicon value & render

This commit is contained in:
Phuong Vu 2024-02-21 22:35:38 +07:00
parent 6d6903ad62
commit d46433c10e
2 changed files with 12 additions and 4 deletions

View file

@ -216,9 +216,13 @@ class SEOManager
}
/** Enable favicon extension. */
public function favicon(): static
public function favicon(string|bool $value = true): static
{
$this->extensions['favicon'] = true;
if (is_string($value) && !empty($value)) {
$this->set('favicon', $value);
}
$this->extensions['favicon'] = !!$value;
return $this;
}