1

我一直在关注“发现流星”一书,在 Iron-Router 部分,他们说要安装

mrt add iron-router

它说

Stand back while Meteorite does its thing
Done installing smart packages
Ok, everything's ready. Here comes Meteor!
=> Running Meteor from a checkout -- overrides project version (0.7.0.1)
iron-router: Routing specifically designed for Meteor

但是当我运行流星......它说:

=> Errors prevented startup:
While building the application:
error: no such package: 'iron-router'

我已经删除并尝试安装..然后更新mrt和meteor,它说:

Installing Meteor
branch: https://github.com/meteor/meteor.git#master
Installing smart packages
✓ iron-router
tag: https://github.com/EventedMind/iron-router.git#v0.6.1
Done installing smart packages

但是当我运行它仍然给出同样的错误,说没有包铁路由器。

有任何想法吗?谢谢

4

3 回答 3

6

确保mrt add iron-router在根目录下执行,而不是从子目录中执行。

于 2014-01-08T05:00:50.113 回答
3

你可以在这里找到这个问题的答案: meteor with mrt - iron:router: no such package

为流星 0.8.3 及更早版本安装 IronRouter :

$ mrt add iron-router

为流星 0.9.0 和更高版本安装 IronRouter :

$ meteor add iron:router
于 2015-05-23T19:22:31.587 回答
0

感谢您的评论。

我忘了用 url http://www.paypertise.com/meteorjs/iron-router-tutorial中的代码编辑 smart.json 感谢托尼霍普金森 的提示

此外,coffeescript 在 Meteor 中的运行也不是很好。

于 2014-01-08T00:24:25.580 回答