Open neoromantic opened 8 years ago
Yes, this is something @mquandalle should add to his compiler. Here is code for HTML files.
As far as it needs a function, have you tried clickHappened: -> -> 1
?
It may be a little bit ugly workaround, but it should work.
Hmm, blaze-magic-events works fine.
Because magic events seems to renders event handlers to DOM to define events. This is much uglier approach.
I'm using mquandalle:jade package to have '.jade' templates in my projects.
When I'm trying to bind events within template, as you recommend to do, it fails.
For example:
component.jade:
component.coffee
When component renders, I get an error:
Error: Event handler not a function: 1
What happens, as far as I understand is that jade compiler executes 'clickHappened' method instead of passing it as an argument.
Is there any way (syntax?) to use Jade with BlazeComponents?