You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Auto-detect of Hilla application based on Hilla views in frontend folder #18577
Vaadin Flow should automatically detect if Hilla views are used or it's a plain Flow application. Flow chooses between hot-deploy mode and bundle mode at startup based on whether any Hilla view exists in the application.
Hilla views are detected based on the existence of frontend/routes.ts, frontend/routes.tsx, the content of routes object and any file inside frontend/views/.
This should replace existing EndpointRequestUtil.isHillaAvailable() checks, as EndpointRequestUtil.isHillaAvailable() is true always now with unified platform.
Additional context
Is there anything else you can add about the proposal?
EndpointRequestUtil.isHillaAvailable() is still useful after adding new method to check if Hilla views are used. It will tell if hilla endpoint is in the classpath (whole hilla could be excluded explicitly for some cases), new method will tell if hilla views are used.
Precisely. And now that you mention that, it probably makes sense to add another utility method called isHillaUsed(File frontnedDir) in EndpointRequestUtil that does that.
Activity
tltv commentedon Feb 2, 2024
EndpointRequestUtil.isHillaAvailable()is still useful after adding new method to check if Hilla views are used. It will tell if hilla endpoint is in the classpath (whole hilla could be excluded explicitly for some cases), new method will tell if hilla views are used.mshabarov commentedon Feb 2, 2024
So "is Hilla used in the project" would mean "isHillaAvailable() AND Hilla views are used".
tltv commentedon Feb 2, 2024
Precisely. And now that you mention that, it probably makes sense to add another utility method called
isHillaUsed(File frontnedDir)inEndpointRequestUtilthat does that.mshabarov commentedon Feb 2, 2024
EndpointRequestUtilis probably not a best place where this should be added, we can create a new util/helper class or extendFrontendUtils.feat: apply auto-detection of Hilla application
feat: apply auto-detection of Hilla application (#18609)
vaadin-bot commentedon Feb 7, 2024
This ticket/PR has been released with Vaadin 24.4.0.alpha3 and is also targeting the upcoming stable 24.4.0 version.
feat: apply auto-detection of Hilla application (#18609)