A web application showcasing a Linked List implementation using a Rust backend and a React frontend.
/project-root
│── /app # Rust backend
│── /web # React frontend
│── README.md
Prerequisites Ensure you have the following installed:
# Install Rust (if not installed)
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
# Install Node.js (if not installed)
# Visit https://nodejs.org/ or use a package manager:
# macOS: brew install node
# Ubuntu: sudo apt install nodejs npm
- Start the Rust Backend
cd app
cargo run
This will start the backend server.
- Start the React Frontend
cd web
npm install # Install dependencies (only needed the first time)
npm run dev
This will start the frontend development server.
Your Rust backend provides an API to interact with a linked list. The available endpoints include:
# Get all elements in the linked list
GET /
# Get the size of the linked list
GET /size
# Add an element to the linked list
POST /add
Body: { "data": <integer> }
# Search for an element in the linked list
GET /search?key=<integer>
# Insert an element at a specific index
POST /insert
Body: { "data": <integer>, "index": <integer> }
# Remove an element from the linked list
POST /remove
Body: { "key": <integer> }
If needed, update the frontend API URL in:
web/src/config.js
# or
web/.env
For deployment, ensure your backend is hosted (e.g., Render) and update the frontend’s API configuration accordingly.
MIT License