Skip to content

Commit dca8a3c

Browse files
committed
updated readme
1 parent b151d21 commit dca8a3c

1 file changed

Lines changed: 56 additions & 47 deletions

File tree

README.md

Lines changed: 56 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -3,33 +3,44 @@
33
[![CI](https://github.com/johnsulf/project-exam-2/actions/workflows/ci.yml/badge.svg)](https://github.com/johnsulf/project-exam-2/actions/workflows/ci.yml)
44
[![Pages Deploy](https://github.com/johnsulf/project-exam-2/actions/workflows/pages.yml/badge.svg)](https://github.com/johnsulf/project-exam-2/actions/workflows/pages.yml)
55

6-
Holidaze web app – browse venues, manage listings, and handle bookings with an improved search experience, inline availability filtering, and post-stay owner ratings.
7-
8-
## Preview image
6+
Holidaze web app – browse venues, create a user to book venues or become a venue manager to create and host your own venues.
97

108
![App preview](public/preview.png)
119

12-
Built with:
10+
---
1311

14-
- React 19 + TypeScript
15-
- Vite 5 (fast dev & bundling)
16-
- Tailwind CSS v4 + shadcn/ui component primitives
17-
- TanStack Query for data fetching & cache
18-
- Zustand for client auth/session state
12+
## Table of Contents
13+
14+
1. [Tech Stack](#tech-stack)
15+
2. [Environment Variables](#environment-variables)
16+
3. [Quick Start](#quick-start)
17+
4. [Scripts](#scripts)
18+
5. [Testing & QA](#testing--qa)
19+
6. [Features](#features)
20+
7. [Required Project Links](#required-project-links)
21+
8. [Project Structure](#project-structure)
22+
23+
---
1924

20-
The project is production-leaning: strongly typed, componentised, and ready for CI/CD. Clone, install, and run in under five minutes.
25+
## Tech Stack
26+
27+
- React 19 + TypeScript
28+
- Vite 5
29+
- Tailwind CSS v4 with shadcn/ui primitives
30+
- TanStack Query
31+
- Zustand
2132

2233
---
2334

2435
## Environment Variables
2536

26-
Most development scenarios work with the defaults, but you can override them via a `.env` file or shell vars:
37+
Override defaults with a `.env` file or shell variables:
2738

28-
| Variable | Default | Purpose |
29-
| ------------------- | -------------------------------- | ----------------------------------------------------- |
30-
| `VITE_API_BASE_URL` | `https://v2.api.noroff.dev` | Switch backend base URL (strip trailing slashes). |
31-
| `VITE_APP_ENV` | inferred from Vite mode | Surface the environment in logs/analytics. |
32-
| `VITE_DEBUG` | `true` in dev, `false` otherwise | Enables extra logging + development-only diagnostics. |
39+
| Variable | Default | Purpose |
40+
| ------------------- | -------------------------------- | ---------------------------------------- |
41+
| `VITE_API_BASE_URL` | `https://v2.api.noroff.dev` | Backend base URL (no trailing slash). |
42+
| `VITE_APP_ENV` | inferred from Vite mode | Exposes environment in logs/analytics. |
43+
| `VITE_DEBUG` | `true` in dev, `false` otherwise | Enables verbose logging and diagnostics. |
3344

3445
Example `.env.local`:
3546

@@ -43,12 +54,12 @@ VITE_DEBUG=true
4354

4455
## Quick Start
4556

46-
Prerequisites:
57+
**Prerequisites**
4758

48-
- Node 20+ (LTS recommended)
49-
- pnpm (install globally: `npm i -g pnpm` if needed)
59+
- Node.js 20+
60+
- pnpm (`npm i -g pnpm`)
5061

51-
Clone & run:
62+
**Setup**
5263

5364
```bash
5465
git clone https://github.com/johnsulf/project-exam-2.git
@@ -57,42 +68,44 @@ pnpm install
5768
pnpm dev
5869
```
5970

60-
Then open the printed local URL (usually http://localhost:5173).
71+
Open the printed local URL (usually http://localhost:5173).
6172

6273
---
6374

6475
## Scripts
6576

66-
| Script | Purpose |
67-
| ---------------- | --------------------------------------- |
68-
| `pnpm dev` | Start Vite dev server with HMR |
69-
| `pnpm build` | Type check then build production bundle |
70-
| `pnpm test` | Run Vitest test suite (CI friendly) |
71-
| `pnpm test:unit` | Interactive test watcher/UI |
72-
| `pnpm test:e2e` | Test with PlayWright |
73-
| `pnpm lint` | Run ESLint over source |
74-
| `pnpm typecheck` | Run TypeScript without emitting |
77+
| Script | Description |
78+
| ---------------- | ----------------------------------------- |
79+
| `pnpm dev` | Start the Vite dev server with HMR |
80+
| `pnpm build` | Type-check and build production bundle |
81+
| `pnpm test` | Run Vitest in CI mode |
82+
| `pnpm test:unit` | Watch mode for unit and integration tests |
83+
| `pnpm test:e2e` | Execute Playwright E2E tests |
84+
| `pnpm lint` | Run ESLint |
85+
| `pnpm typecheck` | Run TypeScript without emitting |
7586

7687
---
7788

7889
## Testing & QA
7990

80-
- **Unit & integration**: `pnpm test:unit` (Vitest + jsdom). Use `pnpm test` for non-watch CI mode.
81-
- **End-to-end**: `pnpm test:e2e` (Playwright). Expects the Vite dev server on `http://localhost:5173`; Playwright takes care of launching it in CI. The suite exercises most user stories (auth, listing/search, booking entry, manager UX), but some management/registration scenarios are still verified manually.
82-
- **Linting & types**: run `pnpm lint` and `pnpm typecheck` locally (they’re part of CI’s `unit` job).
83-
- **Manual QA flows**: see `docs/qa-checklist.md` for sign-off steps covering auth, booking, venue management, and regression smoke tests—kept in sync with the Playwright specs.
91+
- **Unit & integration:** `pnpm test:unit` (Vitest + jsdom). Use `pnpm test` for CI runs.
92+
- **End-to-end:** `pnpm test:e2e` (Playwright). Requires the Vite dev server at `http://localhost:5173`; CI launches it automatically.
93+
- **Linting & types:** `pnpm lint` and `pnpm typecheck` (also wired into CI).
94+
- **Manual QA:** See `docs/qa-checklist.md` for auth, booking, venue management, and regression flows.
95+
96+
Deployment pipelines require all automated test suites to succeed before release.
8497

8598
---
8699

87100
## Features
88101

89-
- Venue search with client-side filtering (name, description, and location fields) plus amenity/date filters
90-
- Mobile bottom-sheet search UI, including inline popover content for dates & filters
91-
- Venue detail gallery with smooth image transitions
92-
- Auth flows (sign in, register customer, register manager) with subtle entry animations and spinner feedback
93-
- Owner dashboard for creating, editing, deleting venues, and managing bookings; responsive cards on mobile
94-
- Profile view with past/upcoming bookings, avatar editing, and owner-only rating updates
95-
- Shared UI based on shadcn/ui + Tailwind utility classes
102+
- Venue search with client-side filtering by text, amenities, and dates
103+
- Mobile bottom-sheet search UI with inline popovers
104+
- Venue detail gallery with smooth transitions
105+
- Auth flows for sign-in, customer, and manager registration
106+
- Owner dashboard for CRUD operations on venues and booking management
107+
- Profile view for bookings, avatar updates, and owner ratings (mock)
108+
- Shared UI built on shadcn/ui and Tailwind utility classes
96109

97110
---
98111

@@ -106,21 +119,17 @@ Then open the printed local URL (usually http://localhost:5173).
106119
- Repository: [GitHub](https://github.com/johnsulf/project-exam-2)
107120
- Live Demo: [Holidaze](https://johnsulf.github.io/project-exam-2/)
108121

109-
Keep these updated for examiner & collaborators.
110-
111122
---
112123

113124
## Project Structure
114125

115126
```
116127
src/
117-
components/ # Reusable UI (incl. auth forms, layout)
128+
components/ # Reusable UI (auth forms, layout, primitives)
118129
features/ # Domain features (venues, bookings, profile, manager)
119130
lib/ # API helpers, query keys, utilities
120131
pages/ # Route-level React components
121132
providers/ # Global context (auth, app)
122133
config/ # Runtime configuration
123-
index.css # Tailwind layers + motion utilities
134+
index.css # Tailwind layers and motion utilities
124135
```
125-
126-
---

0 commit comments

Comments
 (0)