meteor Logging Logging info on the data context in a template helper


The following uses the Chrome Logging API. If the .group() syntax is used in multiple templates, it will graphically organize the console logs from different templates into a hierarchical tree.

You can also see how to inspect the current data context, and how to stringify data.

Template.landingPage.getId = function(){
  // using a group block to illustrate function scoping'coolFunction');

  // inspect the current data object that landingPage is using

  // inspect a specific field of the locally scoped data object

  // close the function scope
  return this._id;