當我使用沒有參數的路由時,我的模板中有正常的路徑。但是,當我加入一些「鼻涕蟲」,是這樣的:在控制檯鐵路由器和路徑
@route "pagesSlug",
path: "/page/:_slug"
name: "page"
,並得到錯誤:
You called Router.path for a route named page but that route doesn't seem to exist. Are you sure you created it?
沒有改變,當我添加/刪除名稱。 我有空{{pathFor ...在我的模板中,而urlFor太空了。
在這種情況下:
@route "articlesList",
path: "/articles"
waitOn:()->
Meteor.subscribe 'articles'
我有HREF = 「/篇」 - 沒問題。
更新:流星0.9.4和鐵路由器0.9.4。
其中鐵路由器版本您使用的是參數_slug? 0.9.4或1.0.0-pre4? – waitingkuo 2014-10-20 07:23:41
0.9.4。對不起,「最新」 – Vladislav 2014-10-20 07:38:50