Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vite.php is not using custom manifest file generated by laravel-vite-plugin #45002

Closed
ngstwr opened this issue Nov 18, 2022 · 2 comments
Closed

Comments

@ngstwr
Copy link
Contributor

ngstwr commented Nov 18, 2022

  • Laravel Version: 9.32
  • PHP Version: 8.1

Description:

Vite.php has 'manifest.json' hardcoded in manifestPath method!

protected function manifestPath($buildDirectory)
{
return public_path($buildDirectory.'/manifest.json');
}

Steps To Reproduce:

  1. Install laravel-vite-plugin
    yarn add laravel-vite-plugin -D

  2. Change manifest file name to 'custom-manifest.json' in vite.config.js
    build: {
    manifest: 'custom-manifest.json',
    }

  3. Build the application
    yarn prod

@driesvints
Copy link
Member

Seems like this is a feature request. Feel free to send in a PR 👍

@ngstwr
Copy link
Contributor Author

ngstwr commented Nov 18, 2022

I don't understand how is this a feature request!

An official plugin 'laravel-vite-plugin', is generating the manifest file and Vite.php facade is using the same manifest file to map and provide resources.

Now, laravel-vite-plugin provides an option to generate manifest, named as per user provided configuration. However Vite.php hasn't been updated to allow this.

Anyway, I don't have a problem sending in a PR, but I am new to Laravel and have no idea on how to write tests!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants