Skip to content

Add Vite driver #3952

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

Merged
merged 6 commits into from
Nov 13, 2022
Merged

Add Vite driver #3952

merged 6 commits into from
Nov 13, 2022

Conversation

Julien-R44
Copy link
Member

@Julien-R44 Julien-R44 commented Oct 26, 2022

Still needs to be tested

  • Add a BaseDriver class that shares commons methods between different Assets drivers
  • Add Vite driver

Several things are worth noting:

  1. Vite does not generate manifests during development. So concretely, it's not really a problem, you can still load the assets. The only drawback is that in dev, if you try to load an asset that doesn't exist, you won't get an error in the terminal console. However, you will obviously get an error in the browser.

  2. Vite does not generate a "entrypoints.json" file like Encore. So I added this feature in the Vite plugin which I will publish soon.

    The vite plugin I made will generate an entrpoints.json file exactly the same way as Encore, in dev and at build time. This will allow us to keep exactly the same API as Encore and especially not create any breaking changes. The helpers entryPointsStyle and entryPointsScripts will be usable in the same way.

@Julien-R44 Julien-R44 mentioned this pull request Oct 26, 2022
11 tasks
@Julien-R44 Julien-R44 marked this pull request as ready for review October 29, 2022 21:35
@thetutlage
Copy link
Member

Everything looks great to me. Spot on!

@thetutlage thetutlage merged commit cbe1813 into develop Nov 13, 2022
@RomainLanz RomainLanz deleted the feat/vite branch November 13, 2022 08:38
@thetutlage thetutlage self-requested a review November 22, 2022 03:13
@thetutlage thetutlage added the Type: Feature Request Request to add a new feature to the package label Nov 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Feature Request Request to add a new feature to the package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants