Using Play Framework, I was wondering if it was possible to load some vars in the template like I do in other controllers.
I mainly think about my “STATIC_URL” var that contains the path to the static files, that changes between my DEV/PROD modes.
Or at least, which alternatives I can use to make this works?
Thanks for your help!
Your question is not very clear and could do with an example of what you are trying to achieve.
However if what I think you are asking is correct try the following in your controller:
Then in your template use ${staticUrl} to access the value from the renderArgs map.