Expose Client Variables as Public References
40
Views
2
Comments
New
Frontend (App Interfaces)

In Reactive Web applications, it is common to have multiple front-end modules within the same application. Currently, Client Variables are scoped to a single module, which creates challenges when we need to share session-like data across modules.

A common workaround is to centralize these variables in one module (_CW) and expose them through public client actions. While this approach works, it introduces some limitations:

  • It increases complexity

  • It requires additional control over events to retrieve the variable

  • It cannot be used in Aggregates or Data Actions, since client actions are not supported in those contexts, even though module-level client variables are

My suggestion is to introduce the ability to mark Client Variables as "Public", allowing them to be accessed across modules via references, similar to how public elements (e.g., actions, structures) are exposed today.

This would enable:

  • Direct access to shared client state across modules

  • Cleaner and more maintainable reuse

  • Elimination of unnecessary client actions and events used to retrieve values

  • Consistent usage of client variables in UI logic and data-fetching layers

This improvement would simplify cross-module state management and reduce the need for workarounds, especially in larger applications with multiple front-end modules.

Nice!

Ignoring the obvious SOLID issues, it would be very helpful.