diff --git a/Vite.php b/Vite.php index b89efed..4066fa9 100644 --- a/Vite.php +++ b/Vite.php @@ -136,7 +136,7 @@ public function __invoke(array|string $entries, string $buildDirectory = null): $args = [ $key, - asset($buildDirectory . '/'. $file = $chunk['file']), + url($buildDirectory . '/'. $file = $chunk['file']), $chunk, $manifest, ]; @@ -156,7 +156,7 @@ public function __invoke(array|string $entries, string $buildDirectory = null): if (! isset($preloads[$file])) { $preloads[$file] = $this->makePreloadTag( $key, - asset($buildDirectory . '/'. $file), + url($buildDirectory . '/'. $file), $chunk, $manifest, ); @@ -172,7 +172,7 @@ public function __invoke(array|string $entries, string $buildDirectory = null): $args = [ $key, - asset($buildDirectory . '/'. $file), + url($buildDirectory . '/'. $file), $chunk, $manifest, ]; @@ -197,7 +197,7 @@ public function __invoke(array|string $entries, string $buildDirectory = null): $args = [ $key, - asset($buildDirectory . '/'. $file), + url($buildDirectory . '/'. $file), $chunk, $manifest, ]; @@ -415,7 +415,7 @@ public function asset(string $asset, string $buildDirectory = null): string $chunk = $this->chunk($this->manifest($buildDirectory), $asset); - return asset($buildDirectory . '/' . $chunk['file'])->url(); + return url($buildDirectory . '/' . $chunk['file']); } /**