Improve readability of DynamicText / Style expressions by allowing Microflow or Nanoflow execution
Current issue
In Mendix, there are cases where DynamicText expressions or Style properties require long and complex expressions.
Examples:
- Multiple nested
if statements - String concatenation
- Complex conditional formatting
- Dynamic CSS generation
As these expressions become longer, readability and maintainability decrease significantly.
Additionally:
- Debugging becomes difficult
- Reusing logic is hard
- Business logic becomes embedded directly in UI components
- Reviewing and maintaining pages becomes more complicated
Suggested improvement
Allow DynamicText and Style properties to execute:
instead of only inline expressions.
For example:
- DynamicText → return value from Nanoflow/Microflow
- Style/Class generation → return style string from Nanoflow/Microflow
Expected benefits
- Improved readability and maintainability
- Easier debugging
- Better separation between UI and logic
- Reusable formatting/styling logic
- Reduced complexity in page editors
- Easier onboarding for new developers
This would be especially helpful in large enterprise applications where UI logic can become very complex.