Skip to content

Commit

Permalink
Fixed __invoke method, isRunningHot now returns corrently
Browse files Browse the repository at this point in the history
  • Loading branch information
monster010 committed Oct 2, 2023
1 parent e231571 commit 808212f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/Helpers/vite_helper.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ function vite_tags($entryPoints, $buildDirectory = null): string
$entryPoints = [$entryPoints];
}

$vite = new Vite();
$vite = new Vite;

return $vite($entryPoints, $buildDirectory);
}
Expand Down
3 changes: 1 addition & 2 deletions src/Vite.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@ public function __invoke($entryPoints, $buildDirectory = null)
if ($this->isRunningHot()) {
array_unshift($entryPoints, '@vite/client');

echo implode(' ', array_map(fn ($entrypoint) => $this->makeTagForChunk($entrypoint, $this->hotAsset($entrypoint), null, null), $entryPoints));
return;
return implode(' ', array_map(fn ($entrypoint) => $this->makeTagForChunk($entrypoint, $this->hotAsset($entrypoint), null, null), $entryPoints));
}

$manifest = $this->manifest($buildDirectory);
Expand Down

0 comments on commit 808212f

Please sign in to comment.