Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/meteor/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Meteor iron路由器包出错_Meteor_Iron Router - Fatal编程技术网

Meteor iron路由器包出错

Meteor iron路由器包出错,meteor,iron-router,Meteor,Iron Router,这是我第一次使用铁路由器包。下面是我的示例代码: Router.configure({ layoutTemplate: 'layout' }); Router.map(funtion(){ this.route('home', { path: '/'}); }); 当我运行此应用程序时。它给出了一个错误: => Errors prevented startup: While building the application: lib/router.js:5:22: Unexpe

这是我第一次使用铁路由器包。下面是我的示例代码:

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

Router.map(funtion(){
  this.route('home', { path: '/'});
});
当我运行此应用程序时。它给出了一个错误:

=> Errors prevented startup:
While building the application:
lib/router.js:5:22: Unexpected token {

=> Your application has errors. Waiting for file change.
=> Modified -- restarting.
=> Errors prevented startup:
我不确定这个简单的代码有什么问题

Router.map(funtion(){
  this.route('home', { path: '/'});
});
函数拼写不正确