Skip to content
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

Use Blaze._getTemplate to allow resolving into Blaze Components #10

Closed
wants to merge 1 commit into from

Conversation

mitar
Copy link

@mitar mitar commented May 10, 2015

With meteor/meteor@eff8016 there is now a Blaze._getTemplate function which is better to use than accessing Template[...] directly. The reason is that then packages like Blaze Components can override Blaze._getTemplate to provide resolving into components instead of bare templates.

I am not 100% sure if:

function () {
  return Template.instance();
}

is the best way to get current template instance, maybe it is available already somewhere in this code-path? But it should work this way as well. But I do not like access to global variables which Template.instance uses internally. So if you know of any better way to access current template instance at that code point, that would be great.

@mitar
Copy link
Author

mitar commented May 11, 2015

Closed in favor of #11.

@mitar mitar closed this May 11, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant