I am trying to create a theme for Drupal 7 with Twig. If I wanted to register a new PHP function, I should implement "hook_twig_function()" as the module explains.
My simple question is: where should I implement my functions? If I write code - as usual - inside my "template.php", I have this alert: "Unknown "my_module_coolfunction" function in "sites/all/themes/abc/templates/page.tpl.twig"
If I edited the "Extension.php" file, after every update, I would lost all my custom functions.