GithubHelp home page GithubHelp logo

felixge / nodeguide.com Goto Github PK

View Code? Open in Web Editor NEW
371.0 50.0 43.0 72 KB

My unofficial and opinionated guide to node.js.

Home Page: http://nodeguide.com/

Makefile 22.12% CSS 43.93% HTML 26.69% Dockerfile 7.26%

nodeguide.com's Introduction

nodeguide.com

Local installation

git clone [email protected]:felixge/nodeguide.com.git
cd nodeguide.com 

Viewing the Guide

With Docker

If you don't know what Docker is, then it will be easiest for you to view the Without Docker instructions, below.

If you do not have a webserver (Apache/ Nginx) running, you will probably have port 80 available, in which case just run:

docker-compose up

If, however port 80 is already taken by a webserver (typical for a development environment), you will see an error like this: Error starting userland proxy: listen tcp 0.0.0.0:80: listen: address already in use. In which case, you can use the "override" file to make it use a different port (e.g. 8080 if that is available):

cp docker-compose.override.yml.dist docker-compose.override.yml
docker-compose -f docker-compose.override.yml up

Without Docker - Debian/ Ubuntu

You can run these commands to view the guide locally, temporarily.

sudo apt install pandoc # if you don't yet have pandoc installed
make
Technology Command Line
PHP php -S localhost:8000
Python python -m SimpleHTTPServer 8000
Python - twistd twistd -n web -p 8080 --path .
Ruby ruby -run -ehttpd . -p8080

Then visit: http://localhost:8000

See Also

nodeguide.com's People

Contributors

ad7six avatar adrianheine avatar felixge avatar leriksen avatar meetar avatar mohammedfadin avatar pvorb avatar rdworth avatar sholsinger avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

nodeguide.com's Issues

Dead link

The link to fabjs in the beginner's guide is dead, it is some "financial blog" now.

Minor typos

On the beginner page, in the installation section:

$ wget http://nodejs.org/dist/node-v0.4.4.tar.gz

$ tar -xzf node-v0.4.4.tar.gz

$ cd node-v0.4.4.tar.gz

$ ./configure

$ sudo make install

I think it would be better to use something such as node-v0.x.x.tar.gz so that it's less obvious that the displayed version is outdated.
Also, cd node-v0.4.4.tar.gz should be cd node-v0.4.4/ (or cd node-v0.x.x/).

Cheers,
Dennis

Style code bug

Maybe it's intentional - the 'Wrong' section in Return-statements is not just bad style, but won't work as expected. The first if condition should probably read 'val >= 0' instead of 'val < 0'.

RSS Feed

Please-please add an rss feed to nodeguide.com so we don't miss another guide :)

Web page not responsive

My monitor is in portrait position, so I rely on responsive web layout to read comfortably. However on nodeguides.com, the texts were overflowing my display screen which required me to scroll right every time I hit line-ends. I ended up printing the docs on paper. Overall, I liked the plain layout.

Code Conventions / Var declaration

I've read your comment about Crockforf and followed the link and he also says to use var the same way as you do :-)
"It is preferred that each variable be given its own line and comment. They should be listed in alphabetical order.

var currentEntry; // currently selected table entry
var level;        // indentation level
var size;         // size of table

"
I copied this code to JSLint and it passes. Seems Crockford changed his mind :-)

«Hello World Tutorial» needs an update

«Hello World Tutorial» currently says:

You should run a *nix operating system in order to use node.js at this point. Linux and OSX are recommended, but you should also be able to use FreeBSD and cygwin (on windows). A full windows port of node.js is in the works, but it is not yet ready for public usage.

A full windows port of node.js is already more or less complete.

Trivial issue

Hey Felix - thanks for the effort you put into the style guide.

Under Array/Object Creation you'll find a trailing comma..

var a = ['hello', 'world'];
var b = {
good: 'code',
'is generally': 'pretty',
};

typo in node beginner's guide (s/data/req)

In first example under EventEmitters:

var data = '';
req
  .on('data', function(chunk) {
    data += chunk;
  })
  .on('end', function() {
    console.log('POST data: %s', data);
  })

Shouldn't that first line be a declaration of 'req' not 'data'?

thanks for the helpful docs!

Small Typo

Hi Felix, wonderful guide!
I noticed in the Style guide under Braces there is a missing quote after winning.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.