Wanderlust is a full-stack travel blogging platform with a browser-based frontend, REST API backend, and a desktop client module. The project includes user authentication, article publishing, comments, profile management, image upload, and admin support.
- User registration and login
- Profile management with avatar/icon support
- Browse, search, sort, and paginate articles
- Create, edit, and delete your own articles
- Comment on articles with nested replies
- Like articles and display comment counts
- Upload images for profile icons and articles
- Backend user roles including admin support
backend/- Node.js Express API serversrc/app.js- main server entry pointsrc/data/- DAO modules and SQLite database initializationsrc/routes/- API router structuresrc/sql/init-db.sql- database schema and sample seed data.env- backend environment configuration
frontend/- SvelteKit web applicationsrc/routes/- frontend page routessrc/lib/components/- reusable UI componentssrc/lib/js/api-url.js- API endpoint configuration.env- frontend API base URL settings
desktop-client/- Java desktop client module for administrative or offline use
- Node.js 18+ (recommended)
- npm
- Svelte
- sqlite3 (optional for manual database initialization)
- Java JDK (if you want to run the admin interface)
-
Open a terminal and go to the backend folder:
cd backend
-
Install dependencies:
npm install
-
Confirm or update
.envvalues. The default backend.envincludes:PORT=3000 JWT_KEY=CS719ISAWESOME DB_FILENAME=project-database.db DB_INIT_SCRIPT=src/sql/init-db.sql FRONTEND_ORIGIN=http://localhost:5173 SALTROUND=10 -
Start the backend server in development mode:
npm run dev
The backend listens on http://localhost:3000 and exposes API routes under /api.
-
Open a second terminal and go to the frontend folder:
cd frontend
-
Install dependencies:
npm install
-
Confirm the frontend
.envvalues. The default file contains:PUBLIC_API_BASE_URL=http://localhost:3000/api PUBLIC_IMAGES_URL=http://localhost:3000/images PUBLIC_SERVER_URL=http://localhost:3000 -
Start the frontend development server:
npm run dev
The frontend runs on http://localhost:5173 by default.
- Start the backend first.
- Start the frontend second.
- Open the browser at
http://localhost:5173.
If the backend database file does not exist, the backend automatically initializes SQLite using backend/src/sql/init-db.sql.
The backend uses SQLite and initialises the database from backend/src/sql/init-db.sql when DB_FILENAME is missing.
If you want to initialize manually, from backend/ run:
sqlite3 project-database.db < src/sql/init-db.sqlYou can log in with these seeded users:
johndoe/Password123.janedoe/Password456!guest/pAssword1!admin/Abc12345@(admin user)
A Java desktop client is available under desktop-client/. It provides a separate UI module and can be built with your Java development environment.
- Backend and frontend communicate via
PUBLIC_API_BASE_URL. - Uploaded images are served from
http://localhost:3000/images. - User authentication uses JWT tokens stored in cookies.
For questions related to the project, please open an issue or contact the project owner via GitHub.