Meteor 为什么我的模板没有反应性?

Meteor 为什么我的模板没有反应性?,meteor,meteor-blaze,meteor-helper,Meteor,Meteor Blaze,Meteor Helper,如果首先打开,然后单击测试链接,将显示角色标签 但是,如果我直接在Chrome的地址栏中打开url并按enter键,则不会显示角色标签 这是我的密码: 在客户端启动中,我订阅了一些内容: Meteor.publish("Roles", function(){ return Roles.find(); }); Meteor.startup(function() { if(Meteor.isClient) { Meteor.subscribe('Roles');

如果首先打开,然后单击测试链接,将显示
角色
标签

但是,如果我直接在Chrome的地址栏中打开url并按enter键,则不会显示
角色
标签

这是我的密码:

在客户端启动中,我订阅了一些内容:

 Meteor.publish("Roles", function(){
   return Roles.find();
 });

 Meteor.startup(function() {
   if(Meteor.isClient) {
     Meteor.subscribe('Roles');
   }
 });
和角色模板:

 Template.roles.helper( {
   allRoles: function() {
     return Roles.find();
   }
 })
html

html

这意味着
isReady()
是被动的?但为什么我的角色标签仍然是空白的

有人能解释一下吗?

server/publish.js

 Meteor.publish("Roles", function(){
   return Roles.find();
 });
client/client.js

Meteor.startup(function() {
  Meteor.subscribe('Roles');
});

 Template.roles.helpers({ // --> .helper change to .helpers
   allRoles: function() {
     return Roles.find();
   }
 })
client/templates.html

<template name="roles">
  <div>
    {{# if Template.subscriptionsReady }}
      {{#with allRoles}}
        <label>{{> role }}</label>
      {{/with}}
    {{ else }}
      loading....
    {{/if}}
  </div>
</template>

<template name="role">
  <div>{{ _id }}</div>
</template>

{{{#if Template.subscriptionsReady}
{{#所有角色}
{{>角色}
{{/与}}
{{else}
加载。。。。
{{/if}
{{{u id}}
当所有订阅

如果我直接在Chrome的地址栏中打开url并按enter键,则不会显示
角色
标签。啊,好的助手({})-->helpers({})??
1
false
1
false
1
true
2
 Meteor.publish("Roles", function(){
   return Roles.find();
 });
Meteor.startup(function() {
  Meteor.subscribe('Roles');
});

 Template.roles.helpers({ // --> .helper change to .helpers
   allRoles: function() {
     return Roles.find();
   }
 })
<template name="roles">
  <div>
    {{# if Template.subscriptionsReady }}
      {{#with allRoles}}
        <label>{{> role }}</label>
      {{/with}}
    {{ else }}
      loading....
    {{/if}}
  </div>
</template>

<template name="role">
  <div>{{ _id }}</div>
</template>