Skip to content

markkamau254/deploying_a_local_server

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Deploying A Local Server

NOTE: THIS IS THE STARTER CODE. FOR THE DEPLOYED CODE, GO TO THE complete_code branch.

System Requirements

  • Node 18+
  • JSON Server
  • A browser capable of running JavaScript (Chrome, Firefox, Safari, or Edge)
  • Operating System (Windows 10+, MacOS, Linux, etc.)
  • A text editor capable of running JavaScript (Visual Studio Code, Vim, Nano, Emacs, Atom, Sublime Text, etc.)
  • RAM >= 4GB
  • Disk space >= 1GB

Installation

To use this repo, follow these steps:

Alternative One

  1. Open the terminal/CLI on your computer.

  2. If you don't have JSON server installed in the terminal, install it globally using the following command:

    npm install -g json-server
    
  3. Clone the repository by running the following command:

    git clone https://github.com/oyieroyier/deploying_a_local_server.git
    
  4. Change directory to the repo folder:

    cd deploying_a_local_server
    
  5. Open it in your Code Editor of choice. If you use VS Code, run the command:

    code .
    

Alternative Two

  • On the top right corner of this page there is a button labelled Fork.

  • Click on that button to create a copy of the repository to your own account.

  • Follow the process described in Alternative One above.

  • Remember to replace your username when cloning.

    git clone https://github.com/your-github-username-here/deploying_a_local_server.git
    

Running the application locally

  • Open the integrated terminal in your code editor and run json-server:

    json-server watch db.json
    
  • Open the index.html file in Mozilla Firefox, Safari or any Chromium-based browser.

  • If using VS Code, you can use the Live Server extension to run the file on the browser for live reloading.

  • Click HERE to install the Live Server extension and to read instructions on how to use it.

Authors

Bob Oyier

License

License: ICL

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 40.0%
  • CSS 37.6%
  • HTML 22.4%