Added the ability to create JS function compilers

Added the ability to create a function compiler which overrides the normal compilation process for a twig function when its compiled for javascript.

This patch is required for the changes in [issue 22](https://github.com/schmittjoh/JMSTwigJsBundle/issues/22) of the [JMSTwigJSBundle](https://github.com/schmittjoh/JMSTwigJsBundle).