gomezsantiago / sample-express-routes

simple node server setup with express routing

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Sample Node Server with Sockets

Branches

The websockets branch contains an example of a webpage hosted by a node.js server with express routing and a custom 404 error page. It also has an example of how to make a websocket connection.


The master branch contains an example server that utilizes socket.io connections to emit stock data obtained from IEX API to it's connected clients


Running the server

once node is installed, all that is required to run the server application is to type ./server.js in the terminal when in the same directory as that file. This should work in a linux based environment, if it doesn't, the first line of code in the server.js file may need to be modified to point to where node is installed in your system. or simply run node server.js


Running the client

the client side of this application is within the web folder, this can be hosted on any other local server, using something like vscode built-in live server for example


About

simple node server setup with express routing


Languages

Language:JavaScript 54.5%Language:HTML 45.5%