Files
Krow-workspace/docs/04-sync-prototypes.md
bwnyasse 969bc13939 feat: add documentation for synchronizing prototypes and script to automate the process
This commit introduces a new document explaining how to synchronize visual prototypes and POCs into the monorepo.
It also adds a script to automate the process of building and copying the prototype files into the `internal/launchpad/prototypes/web/` directory.
The documentation explains the benefits of synchronizing prototypes, the prerequisites, and the steps to synchronize them.
The script automates the process of installing dependencies, building the web application, and copying the resulting `dist/` folder into the `internal/launchpad/prototypes/web/` directory.
This allows developers to easily synchronize prototypes and make them available for local preview and deployment.
2026-01-10 23:04:36 -05:00

2.2 KiB

Synchronization of Prototypes

This document explains how to synchronize visual prototypes and POCs (Proof of Concept) into this monorepo.

Overview

Prototypes are developed in separate repositories (e.g., client-krow-poc). To keep this main repository clean and focused on production code, we do not commit the build artifacts of these prototypes. Instead, we use a synchronization script to bring them in locally.

Key benefits:

  1. AI Context: Once synced, AI tools (like Gemini) can read the prototype code to understand the intended UI/UX and logic.
  2. Local Preview: You can view the prototypes directly through the DevOps Launchpad.
  3. Local Deployment: Allows you to deploy the latest prototypes to Firebase Hosting from your machine.

Prerequisites

The synchronization script assumes that the prototype repository is cloned adjacent to this project directory.

# Navigate to your workspace root
cd ..
# Clone the POC repository
git clone git@github.com:Oloodi/client-krow-poc.git

Your folder structure should look like this:

/workspace
  ├── krow-workforce-web (This repo)
  └── client-krow-poc    (POC repo)

How to Synchronize

Run the following command from the root of this repository:

make sync-prototypes

What this command does:

  1. Navigates to the adjacent client-krow-poc repository.
  2. Installs dependencies (via pnpm).
  3. Builds the web application (pnpm run build).
  4. Copies the resulting dist/ folder into internal/launchpad/prototypes/web/.

Git & AI Behavior

  • Git: The contents of the prototypes/ directories are defined in .gitignore. They will not be committed to this repository.
  • Gemini/AI: These files are not ignored in .geminiignore. Once you run the sync script, the AI will be able to "see" the code and use it as a reference for your tasks.

Deployment to Hosting

If you want to make these prototypes available on the live DevOps Launchpad (launchpad.krowwithus.com), you must:

  1. Run make sync-prototypes on your local machine.
  2. Run make deploy-launchpad-hosting.

Note: As we add mobile prototypes (Flutter), this guide and the script will be updated to include the flutter build web steps.