Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Current »

openIMIS Frontend Installation Guide

This guide provides step-by-step instructions for setting up the openIMIS Frontend (JavaScript) on Windows. Follow these steps to clone the repository, configure the backend port, load configurations, build the project, and start the development server.

Prerequisites

  • Git installed.

  • Node.js and npm installed (preferably the latest LTS version).

  • Command Prompt (cmd.exe) available.

Step-by-Step Instructions

1. Clone the Frontend Repository

Clone the openIMIS Frontend repository from GitHub.

git clone <https://github.com/openimis/openimis-fe_js.git>

2. Navigate to Your Frontend Project Directory

Navigate into the cloned repository directory (openimis-fe_js). Replace path/to with the actual path where you cloned the repository.

cd path/to/openimis-fe_js

3. Configure the Backend Port in package.json

Open the package.json file in your preferred text editor (e.g., Visual Studio Code) and ensure the proxy configuration points to your backend port. Modify the proxy field to match your backend's URL, for example:

"proxy": "<http://localhost:<your> backend port number>"

Replace <your backend port number> with the actual port number your backend is running on.

4. Load Configuration

Run the following command to load necessary configurations for the project:

yarn load-config

5. Build the Project

Build the project for production using:

yarn build

6. Install serve Globally

Install serve, a simple static file server, globally on your system:

yarn global add serve

7. Start the Project

Start the development server using:

yarn start

This command starts the development server. You can now access the frontend in your browser at <http://localhost:3000> (or another port if specified).

Summary

You have now successfully set up and started the openIMIS Frontend on your local machine. Ensure that both the backend server and frontend development server are running and accessible as per your requirements.

  • No labels