科技动态

How do I fix connect.router?

微信扫一扫,分享到朋友圈

How do I fix connect.router?
0

I’m working my way through Node for Front End devs
, and as people on SO have already pointed out
, Connect no longer has a module for routing. Some people have advised using Express, but I’m unsure of the exact syntax.

The example I am working through is hosted here:

github.com/garann/node-for-frontend-devs/blob/master/03-03.js

I would in turn like to finish the tutorial on templating:

js: github.com/garann/node-for-frontend-devs/blob/master/04-02.js

html: github.com/garann/node-for-frontend-devs/blob/master/public/parent.html

and was wondering whether people think it might be better to ditch these Connect based tutes and just learn how to use Express? As routing will most likely require Express anyway..

Thanks to SO excellent spam protection, I’ve had to remove the https:// portion of the github links.

Thanks for any help.

阅读原文...

Node.js Recipes

Interesting Stuff - Week 24

上一篇

Get the name of the original variable for an LLVM value

下一篇

您也可能喜欢

评论已经被关闭。

插入图片
How do I fix connect.router?

长按储存图像,分享给朋友