code: function (path, opts) {
      if (builtInBlockHelpers.hasOwnProperty(path[0]))
        throw new Error("Can't use the built-in '" + path[0] + "' here");
      // Let `{{#if Template.contentBlock}}` check whether this template was
      // invoked via inclusion or as a block helper, in addition to supporting
      // `{{> Template.contentBlock}}`.
      // XXX BACK COMPAT - UI is the old name, Template is the new
      if (path.length >= 2 &&
          (path[0] === 'UI' || path[0] === 'Template')
          && builtInTemplateMacros.hasOwnProperty(path[1])) {
        if (path.length > 2)
          throw new Error("Unexpected dotted path beginning with " +
                          path[0] + '.' + path[1]);
        return builtInTemplateMacros[path[1]];
      }
  
      var firstPathItem = BlazeTools.toJSLiteral(path[0]);
      var lookupMethod = 'lookup';
      if (opts && opts.lookupTemplate && path.length === 1)
        lookupMethod = 'lookupTemplate';
      var code = 'view.' + lookupMethod + '(' + firstPathItem + ')';
  
      if (path.length > 1) {
        code = 'Spacebars.dot(' + code + ', ' +
          _.map(path.slice(1), BlazeTools.toJSLiteral).join(', ') + ')';
      }
  
      return code;
    }
docs: `path` is an array of at least one string.  If `path.length > 1`, the generated code may be reactive (i.e. it may invalidate the current computation).  No code is generated to call the result if it's a function.  Options:  - lookupTemplate {Boolean} If true, generated code also looks in the list of templates. (After helpers, before data context). Used when generating code for `{{> foo}}` or `{{#foo}}`. Only used for non-dotted paths.