JMSTwigJsBundle
JMSTwigJsBundle copied to clipboard
Twig.js update?
There is missing filters. Like date format and number format... Looking at latest Twig.js sources i can see them... But can't use in my project... Manualy updating Twig.js file don't help... It just different file... And it is highly obfuscated... even in dev version...
The date filter doesn't exist in Twig.js as far as I know. See issue #11 in the actual Twig.js repo. It can't really be implemented with the exact same functionality as Twig (PHP) without a lot of code.
I had to add my own runtime filter. It's not too hard to do. I just kept it simple and only supported the date character parameters I needed.
I think you are wrong! https://github.com/justjohn/twig.js/blob/master/twig.js#L1255
Oh... two different "twig.js" projects... and why this one was chosen to be in the bundle...
PS: I was using swig.js with my recent nodejs project, and i was more or less happy... But i'm totaly unhappy with this bundle... =\
@adam-lynch How did you add runtime filter? Can't get it to work... #34
@adam-lynch Same for Compile time... Can't get a compiler to configure it...
@USvER hmm, I don't remember exactly. See my issue back from back then (#18), it might help.
I just noticed a few other issues now about adding filters. Hmm.
Oh, I meant to say that I don't have access to that code anymore.
@adam-lynch Assetic gives me 500 error on templates that use not existing at compile-time filters #34, and #18 does not give me a clue why it's happen...