Getting started with node.js
I really liked Heroku's getting started guide on Node.JS
https://devcenter.heroku.com/articles/getting-started-with-nodejs#introduction
what are the languages and frameworks I need to know before starting with Node.JS?
The only pre-requisite is JavaScript .
You don't need to be an expert with a lot of programming experience but you should know the basics .
Start with node.js as a complete server-side newbie?
Have no fear. Programming is all about practice and you will do mistake while writing code. But, that is how we all have learnt. Whether it is Ruby, Javascript (via Node.js), or any other language: certain aspects of programming are common and you will get familiar with things specific to that particular language over time. Being not able to remember a syntax or convention is OK. Just have reference material on your side. In fact it is encouraged to tinker and experience "let's see what happens ?" moments. This is how you learn, IMHO.
Node.js is indeed a great choice to start learning server side web development. No doubt about that. You don't have to learn Javascript first and then start learning node. Here you can find all the resources you may want. Also, have a look at this How do I get started with Node.js
Here is what I would recommend as your learning path. This is not even node.js 101. But, it will be a great start.
- Hello World on console. Dead simple and lot of fun
- Math Addition. ( Nothing to do with server development, can skip, but good if you learn it ! )
- Addition of hard coded inputs.
- Addition where function add(a,b) is written in another .js file. Boy, now you are creating libraries !
- Math addition where input is provided using command line. TIP: Use https://github.com/substack/node-optimist
- Hello World on web page.
- Hello World for web but without express.js to start with. Here is the code - http://nodejs.org/
- Hello World for web with http://expressjs.com/.
- Adding some dynamism to the response. e.g Saying what time of day it is.
- Responding based on the URL paths and query string.
- Serving static files such as images and css.
After completing this many tasks you will be good enough to decide what next you want to do.
Node.js server won't run after I put it in a module
You are not calling the function, try:
server.start();
Getting started with Node.js and JavaScript
Console2 is not necessary, it is just a wrapper to a shell like
cmd.exe
I'm guessing you've gone into the REPL function. Further explanation of REPL at Wikipedia.
If the server has been terminated you won't be able to see any new stuff at
http://localhost
, what you'll see is cached content.They are explaining how to run it from a command prompt(
cmd.exe
).
Related Topics
Is There an "Exists" Function For Jquery
How to Select Text Nodes With Jquery
What Does the Exclamation Mark Do Before the Function
Why Can't I Directly Modify a Component'S State, Really
All Falsey Values in JavaScript
Formatting a Number With Exactly Two Decimals in JavaScript
How to Check If an Object Has a Specific Property in JavaScript
How to Disable Scrolling Temporarily
JavaScript: Do I Need to Put This.Var For Every Variable in an Object
Create and Save a File With JavaScript
Why Is Setstate in Reactjs Async Instead of Sync
Generate Random String/Characters in JavaScript
How to Get Image Size (Height & Width) Using JavaScript
Jquery Selector Regular Expressions
Passing Data Between Controllers in Angular Js