Skip to content

Commit

Permalink
fix condition
Browse files Browse the repository at this point in the history
  • Loading branch information
jrmajor committed Nov 22, 2024
1 parent 2a59a42 commit 7d93e00
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Ssr/HttpGateway.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,10 @@ public function __construct(
public function dispatch(array $page): ?Response
{
if ($this->vite->isRunningHot()) {
// todo: maybe ask laravel to make Vite::hotAsset() public
// $url = $this->vite->hotAsset('render');
$url = file_get_contents($this->vite->hotFile()).'/render';
} elseif (config('inertia.ssr.enabled', true) || (new BundleDetector)->detect()) {
} elseif (config('inertia.ssr.enabled', true) && (new BundleDetector)->detect()) {
$url = str_replace('/render', '', config('inertia.ssr.url', 'http://127.0.0.1:13714')).'/render';
} else {
return null;
Expand Down

0 comments on commit 7d93e00

Please sign in to comment.