Skip to content

Commit 0f65c8c

Browse files
authored
Merge pull request #1 from jaguarch/jaguarch-patch-1
fix: viteTags helper
2 parents 2fec09e + 87be25e commit 0f65c8c

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

src/Helpers/vite_helper.php

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,16 @@
55
/**
66
* Get vite entry file or bundled files.
77
*
8-
* @return array|null
8+
* @return string|null
99
*/
10-
function viteTags(): ?array
10+
function viteTags(string $assets): ?string
1111
{
12-
return Vite::tags();
12+
if (in_array($assets, ['js', 'css']))
13+
{
14+
return Vite::tags()[$assets];
15+
}
16+
17+
return null;
1318
}
1419

1520
/**

0 commit comments

Comments
 (0)