Prerequisites
Before you begin, make sure you have the following installed:Node.js
Version 18.x or higher
npm
Comes bundled with Node.js
Git
For cloning the repository
Python Backend
Backend API server (optional for development)
Installation
Install dependencies
Install all required npm packages:This will install the following key dependencies:
- React 19.2.0
- React Router DOM 7.9.6
- SweetAlert2 11.26.3
- TypeScript and Vite dev tools
Configure environment variables
Create a
.env file in the project root and configure the backend API URL:The
VITE_ prefix is required for Vite to expose the variable to the client-side code.Start the development server
Launch the Vite development server:The application will start on
http://localhost:5173 by default.Expected output
Expected output
Available Scripts
The project includes several npm scripts defined inpackage.json:
| Script | Command | Description |
|---|---|---|
dev | vite | Start development server with hot reload |
build | tsc -b && vite build | Type-check and build for production |
lint | eslint . | Run ESLint to check code quality |
preview | vite preview | Preview production build locally |
Development Workflow
Troubleshooting
Backend connection errors
Backend connection errors
If you see “Cannot connect to server” errors:
- Verify the backend is running on the configured port
- Check the
VITE_API_BASE_URLin your.envfile - Ensure no firewall is blocking the connection
api.ts:Port already in use
Port already in use
If port 5173 is already in use, Vite will automatically try the next available port. You can also specify a custom port:
TypeScript errors
TypeScript errors
If you encounter TypeScript errors during build:
- Make sure all dependencies are installed:
npm install - Delete
node_modulesand reinstall:rm -rf node_modules && npm install - Check TypeScript version:
npx tsc --version(should be ~5.9.3)
File upload size limits
File upload size limits
The application supports files up to 24MB. If you need to increase this:
- Update the frontend validation in your upload component
- Configure the backend to accept larger files
- Consider adjusting nginx/reverse proxy limits if deployed
Development Tips
The app uses React 19’s new features. Make sure to familiarize yourself with the latest React patterns if you plan to extend the codebase.
Project Structure
Building for Production
When you’re ready to deploy:Next Steps
Now that you have MkDowner running, explore these topics:File Upload
Learn about the drag-and-drop functionality
Components
Explore the React component architecture
Custom Hooks
Understand the useFileUpload hook
API Integration
Connect to the backend conversion service