Running the frontend - FEUP-MEIC-DS-2024-25/ai4sd GitHub Wiki
How to run the frontend locally
This document main purpose is to help anyone who needs to run the frontend component of AI4SD
in their own computer. The process was tested on Ubuntu, Arch Linux, and WSL 2.0, but there should be support to other operating systems.
We ask anyone who is more experienced with these technologies to improve this document.
Everything that is in italic is temporary, and should be deleted when no longer needed.
Clone Frontend
Clone the frontend from the AI4SD
repository.
git clone [email protected]:FEUP-MEIC-DS-2024-25/ai4sd.git
cd ai4sd
As the main branch is not yet updated, change to the general-app
branch using:
git checkout general-app
Using docker-compose
The most straightforward way to run the frontend component locally is using docker-compose
. We will assume you have it installed. If not, follow Docker compose install guide.
Travel to the frontend directory and run:
cd frontend/webapp/
docker-compose up
This should open the frontend component in the url localhost:3000
.
If some error happens during the docker-compose up
first command, running it again seems to solve the issue. More details are needed if someone knows more about it.
Using npm and nvm
This version was not tested, so report improve this as needed:
- Install nvm / nvm-windows
- Use
nvm
to installnpm 18.8
(Seems to be the version used by the project) - Go to the frontend directory
cd frontend/webapp/
- run
npm install
- run
npm run dev
Other issues
The page may have a compile error due to a module not found
. Simply go to src/app/components/
and rename AssistantInteraction.js
to assistantInteraction.js
. This should no longer be needed once this branch is fixed and merged into the main.
Edits
- 11/11/2024 - Marco Costa (T04G01) - Created document.
- 11/11/2024 - Marco Costa (T04G01) - Fixed links to nvm.