Blaze.Unless

Client Blaze.Unless(conditionFunc, contentFunc, [elseFunc]) import { Blaze } from 'meteor/blaze' Source An inverted Blaze.If. Arguments conditionFunc Function A function to reactively re-run. If the result is falsy, contentFunc is shown, otherwise elseFunc is shown. An empty array is considered falsy. contentFunc Function A Function that returns renderable content. elseFunc Function Optional. A Function that returns renderable content. If no elseFunc is supplied, no content i

Blaze.toHTMLWithData

Client Blaze.toHTMLWithData(templateOrView, data) import { Blaze } from 'meteor/blaze' Source Renders a template or View to HTML with a data context. Otherwise identical to Blaze.toHTML. Arguments templateOrView Blaze.Template or Blaze.View The template (e.g. Template.myTemplate) or View object from which to generate HTML. data Object or Function The data context to use, or a function returning a data context.

Blaze.toHTML

Client Blaze.toHTML(templateOrView) import { Blaze } from 'meteor/blaze' Source Renders a template or View to a string of HTML. Arguments templateOrView Blaze.Template or Blaze.View The template (e.g. Template.myTemplate) or View object from which to generate HTML.

Blaze.Template

Client new Blaze.Template([viewName], renderFunction) import { Blaze } from 'meteor/blaze' Source Constructor for a Template, which is used to construct Views with particular name and content. Arguments viewName String Optional. A name for Views constructed by this Template. See view.name. renderFunction Function A function that returns renderable content. This function is used as the renderFunction for Views constructed by this Template.

Blaze.renderWithData

Client Blaze.renderWithData(templateOrView, data, parentNode, [nextNode], [parentView]) import { Blaze } from 'meteor/blaze' Source Renders a template or View to DOM nodes with a data context. Otherwise identical to Blaze.render. Arguments templateOrView Blaze.Template or Blaze.View The template (e.g. Template.myTemplate) or View object to render. data Object or Function The data context to use, or a function returning a data context. If a function is provided, it will be reactiv

Blaze.render

Client Blaze.render(templateOrView, parentNode, [nextNode], [parentView]) import { Blaze } from 'meteor/blaze' Source Renders a template or View to DOM nodes and inserts it into the DOM, returning a rendered View which can be passed to Blaze.remove. Arguments templateOrView Blaze.Template or Blaze.View The template (e.g. Template.myTemplate) or View object to render. If a template, a View object is constructed. If a View, it must be an unrendered View, which becomes a rendered View a

Blaze.remove

Client Blaze.remove(renderedView) import { Blaze } from 'meteor/blaze' Source Removes a rendered View from the DOM, stopping all reactive updates and event listeners on it. Arguments renderedView Blaze.View The return value from Blaze.render or Blaze.renderWithData.

Blaze.isTemplate

Client Blaze.isTemplate(value) import { Blaze } from 'meteor/blaze' Source Returns true if value is a template object like Template.myTemplate. Arguments value Any The value to test.

Blaze.If

Client Blaze.If(conditionFunc, contentFunc, [elseFunc]) import { Blaze } from 'meteor/blaze' Source Constructs a View that renders content conditionally. Arguments conditionFunc Function A function to reactively re-run. Whether the result is truthy or falsy determines whether contentFunc or elseFunc is shown. An empty array is considered falsy. contentFunc Function A Function that returns renderable content. elseFunc Function Optional. A Function that returns renderable conte

Blaze.getView

Client Blaze.getView([element]) import { Blaze } from 'meteor/blaze' Source Gets either the current View, or the View enclosing the given DOM element. Arguments element DOM Element Optional. If specified, the View enclosing element is returned.