DigiComp.FluidCurrentContro.../README.md

14 lines
650 B
Markdown
Raw Normal View History

# DigiComp.FluidCurrentControllerExpression
This extends the fluid language with an expression to allow you to access values of the current action request.
```html
<html>
<title>Welcome to {#currentController.name} {#currentController.actionName}</title>
</html>
```
The pattern is `{#currentController.PROPERTY_OF_ACTIONREQUEST}` - all properties are possible. To avoid duplicated "controller" in the expression you are allowed to omit them (even if it works, if you do not).
It is really helpful if you try to generalize partials - being an expression, it is not depending on any aliased namespace, which might change in deeper structures.