Skip to content

Add captainhotel file#7

Open
Nisheeka1604 wants to merge 1 commit into
FossHack-26:mainfrom
Nisheeka1604:add-captainhotel-file
Open

Add captainhotel file#7
Nisheeka1604 wants to merge 1 commit into
FossHack-26:mainfrom
Nisheeka1604:add-captainhotel-file

Conversation

@Nisheeka1604
Copy link
Copy Markdown
Contributor

chore: Monorepo setup, lint, format, and pre-commit hooks

Summary

Adds a proper monorepo layout and developer tooling for FOSS Hack 2026.

Changes

Monorepo

  • apps/web — Next.js 15 app (layout + home page)
  • apps/api — Express + TypeScript API with /health and CORS
  • packages/shared — Shared TypeScript types (User, NowPage)

Code quality

  • ESLint 9 (flat config) + TypeScript ESLint at root; next lint in apps/web
  • Prettier for formatting (root config)
  • Husky + lint-staged — pre-commit runs eslint --fix and prettier --write on staged files only

CI

  • GitHub Actions — on push/PR to main: install, lint, format check

Docs & config

  • docs/getting-started.md — install, run API + web, env, scripts
  • docs/contributing.md — dev setup, lint/format, PR guidelines
  • CONTRIBUTING.md — points to docs
  • .env.example — PORT, DATABASE_URL, JWT_SECRET, NEXT_PUBLIC_API_URL

How to test

npm install
npm run dev:api   # terminal 1 — API on :4000
npm run dev:web   # terminal 2 — Web on :3000

Run npm run lint and npm run format:check at root to verify CI.

Checklist

  • Monorepo structure (apps/web, apps/api, packages/shared)
  • ESLint + Prettier configured
  • Pre-commit hook (lint-staged)
  • GitHub Actions lint workflow
  • Docs and .env.example

@Nisheeka1604 Nisheeka1604 force-pushed the add-captainhotel-file branch from 7f1d429 to 747fe7c Compare March 5, 2026 08:40
Copy link
Copy Markdown
Member

@GaneshAdimalupu GaneshAdimalupu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Sanitize all user input before injecting into HTML (critical)
  • Add Escape key listener to close the modal
  • Seed generateMiniBooks / generateShelfBooks from roomId for stable room appearance
  • Consider at minimum sessionStorage for guest state persistence

The file is well-written and clearly built with care — the XSS issue is the only blocker for merging.

@GaneshAdimalupu
Copy link
Copy Markdown
Member

GaneshAdimalupu commented Mar 5, 2026

@Nisheeka1604 Can you tell me why do we have at the root level ?

client/
interface/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants