Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Difference between http-server and http #120

Closed
iamdriz opened this issue Jan 3, 2015 · 1 comment
Closed

Difference between http-server and http #120

iamdriz opened this issue Jan 3, 2015 · 1 comment

Comments

@iamdriz
Copy link

iamdriz commented Jan 3, 2015

What's the difference between this module and the http module that is part of Node core?

@indexzero
Copy link
Collaborator

The core Node.js http module (see: API reference) is just that: a module to interact with HTTP in Javascript.

In contrast, http-server (see: API reference) is not meant to be used as a module, but as a stand-alone static file available via a CLI tool of the same name: http-server. In this way it is more comparable to other tools on the Big list of http static server one-liners.

If you're looking for a module that can serve static files check out ecstatic (which is used by http-server), node-static, or st.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants