Skip to content

linkManager().getCurrentRoute() not handled for WC/iframe micro frontends #5298

Description

@JohannesDoberer

Description

The getCurrentRoute() API on linkManager() (including fromClosestContext(), fromContext(), fromParent(), and fromVirtualTreeRoot() variants) does not work in the UI5 library.

Root Cause

The Luigi Container dispatches a GET_CURRENT_ROUTE_REQUEST event on the container element when a micro frontend calls LuigiClient.linkManager().getCurrentRoute(). However, no addEventListener for this event is registered in the library's container setup code (unlike other events like NAVIGATION_REQUEST, ALERT_REQUEST, etc. which are all handled).

The Promise returned by getCurrentRoute() never resolves.

Expected Behavior

The library should handle the GET_CURRENT_ROUTE_REQUEST event and respond with the current route, similar to how it's handled in the original Luigi framework.

Steps to Reproduce

  1. Configure a WC node with webcomponent: true and a navigationContext
  2. Inside the WC, call this.LuigiClient.linkManager().fromClosestContext().getCurrentRoute()
  3. The returned Promise never resolves

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions