Skip to content

Commit 08df98c

Browse files
authored
fix(vite): fall back to global entrypoints if supplied ones are empty (#870)
1 parent 4138fac commit 08df98c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Tempest/Vite/src/Vite.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,9 @@ public function setNonce(string $nonce): void
4747
*/
4848
public function getTags(?array $entrypoints = null): array
4949
{
50-
return $this->getTagsResolver()->resolveTags($entrypoints ?? $this->viteConfig->build->entrypoints);
50+
return $this->getTagsResolver()->resolveTags(
51+
array_filter($entrypoints ?: []) ?: array_filter($this->viteConfig->build->entrypoints ?: []),
52+
);
5153
}
5254

5355
/**

0 commit comments

Comments
 (0)