Files
OpenHands/frontend
sp.wack 27246aca7e refactor(frontend): Terminal (#1315)
* create new modal for loading previous session

* style and replace modal

* retire old components and group modals into folder

* Utilise i18n for text content and add en translations

* prevent modal from being dismissed via the backdrop

* reference issue that its fixing

* fix incorrect role in tests

* initial commit'

* add output support

* update addon-fit library and mgirate to useXTerm

* add test todos

* move useXTerm to hooks folder

* Fix import path error

---------

Co-authored-by: Jim Su <jimsu@protonmail.com>
2024-04-24 02:34:46 +00:00
..
2024-04-17 17:28:16 +00:00
2024-04-04 16:38:19 -04:00
2024-04-24 02:34:46 +00:00
2024-04-21 14:50:48 -04:00
2024-04-04 16:38:19 -04:00
2024-04-04 16:38:19 -04:00
2024-03-18 21:31:51 -04:00

Getting Started with the OpenDevin Frontend

Available Scripts

In the project directory, you can run:

npm run start -- --port 3001

Runs the app in the development mode.
Open http://localhost:3001 to view it in the browser.

The page will reload if you make edits.
You will also see any lint errors in the console.

npm test

This command runs the available test suites for the application. It launches the test runner in the interactive watch mode, allowing you to see the results of your tests in real time.

npm run build

Builds the app for production to the dist folder.
It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.
Your app is ready to be deployed!

Environment Variables

You can set the environment variables in frontend/.env to configure the frontend. The following variables are available:

VITE_BACKEND_HOST="127.0.0.1:3000" // The host of the backend
VITE_USE_TLS="false"               // Whether to use TLS for the backend(includes HTTPS and WSS)
VITE_INSECURE_SKIP_VERIFY="false"  // Whether to skip verifying the backend's certificate. Only takes effect if `VITE_USE_TLS` is true. Don't use this in production!
VITE_FRONTEND_PORT="3001"          // The port of the frontend

You can also set the environment variables from outside the project, like exporter VITE_BACKEND_HOST="127.0.0.1:3000".

The outside environment variables will override the ones in the .env file.

Learn More

You can learn more in the Create React App documentation.

To learn React, check out the React documentation.

For more information on tests, you can refer to the official documentation of Vitest and React Testing Library.