WortWunder is an interactive German language learning platform featuring multiple engaging games to help students practice vocabulary, spelling, and comprehension.
- Multiple Choice Quiz: Test vocabulary knowledge with interactive multiple-choice questions
- Spelling Bee: Practice German word spelling with audio pronunciation support
- Flashcards: Review vocabulary with digital flashcards
- CEFR Level Support: Content filtered by CEFR language proficiency levels
- Audio Support: Text-to-speech for German word pronunciation
- React with TypeScript
- Vite
- Tailwind CSS
- Lucide Icons
- React Router
- TanStack Query
- Python
- Flask
- SQLite
- SQLAlchemy
- Node.js (v18 or higher)
- Python (v3.8 or higher)
- pip (Python package manager)
- Git
git clone https://github.com/yourusername/wortwunder.git
cd wortwunder# Navigate to backend directory
cd wortwunder-backend-flask
# Create and activate virtual environment
python -m venv venv
source venv/bin/activate # On Windows: .\venv\Scripts\activate
# Install dependencies
pip install -r requirements.txt
# Initialize and start the Flask server
PORT=5006 python app.py # This will create the database and start the server on port 5006The backend will:
- Create and initialize the database with vocabulary data
- Start the Flask server on port 5006 (you can change this by setting the PORT environment variable)
# Open a new terminal and navigate to frontend directory
cd wortwunder-launchpad
# Install dependencies (Note: You may see some npm warnings, these are normal)
npm install
# Create .env file with the backend URL (use the same port as in Step 2)
echo "VITE_API_URL=http://localhost:5006" > .env
# Start the development server
npm run devThe application should now be running at:
- Frontend: http://localhost:5173 (or another port if 5173 is in use)
- Backend: http://localhost:5006 (or your custom port)
You can access the application by opening the frontend URL in your browser. The backend API will be automatically used by the frontend.
Note: If you see npm warnings during installation, these are normal and won't affect the application's functionality.
The init_db.py script creates and populates the SQLite database with:
- Vocabulary table with German-English word pairs
- CEFR levels for each word
- Example sentences
If you encounter database issues:
- Stop both frontend and backend servers
- Delete the existing database file:
cd wortwunder-backend-flask rm instance/vocabulary.db - Recreate the database:
flask db upgrade python init_db.py
To backup your database:
cd wortwunder-backend-flask
sqlite3 instance/vocabulary.db ".backup 'backup.db'"To restore from backup:
cd wortwunder-backend-flask
sqlite3 instance/vocabulary.db ".restore 'backup.db'"GET /api/vocabulary: Get all vocabulary itemsGET /api/vocabulary?level=A1: Get vocabulary filtered by CEFR levelPOST /api/vocabulary: Add new vocabulary itemPUT /api/vocabulary/<id>: Update vocabulary itemDELETE /api/vocabulary/<id>: Delete vocabulary item
- Frontend: https://lucent-griffin-a98935.netlify.app
- Backend API: https://mimivader.pythonanywhere.com
The frontend is deployed on Netlify with the following configuration in netlify.toml:
[build]
command = "npm install && npm run build"
publish = "dist"
[build.environment]
NODE_VERSION = "18"
# API URL is configured in Netlify environment settings
[[redirects]]
from = "/*"
to = "/index.html"
status = 200The backend is hosted on PythonAnywhere. Key configuration points:
- Python version: 3.8
- WSGI configuration file:
wsgi.py - Required files:
app.py,requirements.txt
To update the backend:
- Log in to PythonAnywhere dashboard
- Pull the latest changes from GitHub
- Reload the web app
- Development: Create a
.envfile in the frontend directory with your local API URL - Production: Configure the API URL in your Netlify environment settings
- Environment variables and sensitive paths are configured directly in the hosting platforms
- Database credentials and paths should never be committed to the repository
- Use environment-specific configuration for database paths and credentials
- Fork the repository
- Create a feature branch:
git checkout -b feature-name - Commit your changes:
git commit -m 'Add feature' - Push to the branch:
git push origin feature-name - Submit a pull request
This project is licensed under the MIT License - see the LICENSE file for details.