Skip to content
Preeti edited this page Sep 28, 2022 · 1 revision

Welcome to the Oncosplice-server wiki!

This is a Node.js server for interacting with postgres server.

Running and Installation:

What does a server do?

Opens up a port to listen for incoming requests from clients Defines what to do with each request that comes in (the server's response). To initialize this project do the following steps:

  • git clone

  • npm init

  • npm install . (this will install all the dependencies from package.json)

To download and install an NPM package(express)into our project,we will need to run the following command from your terminal (make sure you are in your project’s root folder when you run this):

  • npm i -s express

-i is a shorthand alias for --install, you can use either. This will add express to a folder called node_modules in your root project folder.

-s is a shorthand alias for --save , you can use either. This is a tag you can add to your npm install command to automatically save it to your package.json.

React.js or any other js framework look for index.js files as the entry point for that particular directory.

To add new dependencies:

const = require('')

Package name

"require" - require() is a built-in Node function that lets you gain access to another Node file’s code. You use this for every dependency you bring into your Node server, and you can also write your own Node files and import them into your main server file the same way.

should be the exact name of the folder or file you wish to import

Clone this wiki locally