开发者_运维问答
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this questionIs it possible to learn ExpressJS without much prior knowledge of Node.js?
Is this a good approach? If yes, what resources can you recommend that I use to learn Express?
Yes of course, it's possible to learn expressJS without NodeJS. Even if it's always better to know both.
The best way to learn expressJS is the official guide :
http://expressjs.com
It is not a good idea to try to use Express before learning node.js basics. You really do need to understand the fundamentals of async because the node.js library modules are all async.
However, it shouldn't require more than a couple of days of studying some of the node.js tutorials and exploring modules like Promises and Steps.
Simple answer is yes, but it's not recommended, you can learn more about Express on their site.
Why is this not a good idea, well simply becuase nodeJS has programming standards, where you have to learn about the Disk I/O and cycle counts before you dive into coding, the reason for this is Node is designed to be Non-Blocking meaning that every action you perform in node that requires the disk to spin up or network access requires it to be compliant with its event structure.
For example:
require('http').createServer(function(Request, Response){
/*
* If your code here is blocking every request that comes in to the server get's bottlenecked.
*/
});
Because if this reason alone i would start on the video presentations around the net to start getting an understanding, and then hit the Node API before you attempt to create anything in node.
Why do you not wish to learn Node before you attempt to learn a module for node?
What I also advise is for you to get a IRC Chat and visit the #node.js channel as the guys over there will help you immensely.
精彩评论