I have a path that needs alot of arguments:
{{ path('work_path', {'username': work.user.username, 'work_id': work.id, 'work_slug': work.slug}) }}
Instead of using this long line everywhere I want to have a specific function for this path only.
Is there a way to call the path() function from my custom function (besides passing the Router service to the extension class)?
As one of possible solutions, you might be interested in writing your own twig macro.