-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Events are not binding with dynamic import in meteor 1.5 #8
Comments
The way this library works at the moment is by going through all defined templates & events, finding the "magic" ones, then making template helpers for those. If a template's JS is dynamically loaded, then this library will not be able to process it. 2 possible solutions I can see for this: a) Hook into the meteor build process and generate "magic" helper code at build time. Solution b) might be the easier one, so I'll look into that one first. If you know or want to help me find out how to either a) hook into the meteor build process (generating code is not a problem) or b) latch on to dynamic import and do post-processing, that would help speed up the solving of this issue. (I personally am not using Meteor at all at the moment, so I don't have an itch of my own to scratch with this.) |
Hello @WayneUong @seeekr , Try this solution. Let me know if this work for you |
@dr-dimitru Is there a global |
@WayneUong no, not yet. Could you submit a new issue? And mention it should be in a next form: FlowRouter.globals.push({
waitOn() {
return [import(/*...*/)];
}
}); |
This is how I set it up in
/client/index.js
In
/imports/client/main.js
:In
/imports/client/main.html
:The onclick event binding does not work.
The text was updated successfully, but these errors were encountered: