SAP / open-ux-tools

Enable community collaboration to jointly promote and facilitate best in class tooling capabilities
Apache License 2.0
82 stars 33 forks source link

TBI - Prepare preview middleware for UI5 2.0 #1679

Open tobiasqueck opened 4 months ago

tobiasqueck commented 4 months ago

Description (include screenshots)

Internal testing of the preview middleware with a preliminary version of UI5 2.0 has shown issues in the code. This ticket is to track (and solve) these issues.

Value

Getting the preview middleware ready for UI5 2.0.

Architecture Elaboration

All fixes are expected in the preview-middleware-client module

Notes

Tasks

codeworrior commented 4 months ago

Small corrections to avoid misunderstandings:

zdravko-georgiev commented 1 month ago

For FLP Sandbox and UI5 2.0 we've discussed the following options:

  1. We explicitly expect the user to tell us
    • We add a new config property to the preview-middleware of type boolean allowing to switch to the new sandbox
    • We add a url parameter with the same effect
    • We add a env variable with the same effect
  2. We add a handler for both urls to the preview-middleware and if either of them returns a 404, we just redirect to the other. Tricky part here: we don’t know if the preview middleware is executed before or after the ui5-proxy middleware (or any other that might be serving the sources)
  3. We create our own bootstrap script that checks the UI5 version and then depending on the result pick one or the other

The decision is to go for option 3.