Meteor Routing Returns "[Object Object]"

I am currently reviewing the Discover Meteor book and got an unexpected result that is different from the result the book suggests.

Immediately after installing the iron router, I followed the book and connected router.js

with layout.html

, but instead get [object Object]

messages instead.

my code:

layout.html

<template name="layout">
  <div class="container">
    <header class="navbar">
      <div class="navbar-inner">
        <a class="brand" href="{{pathFor 'postsList'}}">Microscope</a>
      </div>
    </header>
    <div id="main" class="row-fluid">
      {{yield}}
    </div>
  </div>
</template>

      

router.js

Router.configure({
  layoutTemplate: 'layout'
});

Router.map(function() {
  this.route('postsList', {path: '/'});
});

      

+3


source to share





All Articles