Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/TheSerchCp/SEAM/llms.txt

Use this file to discover all available pages before exploring further.

Getting SEAM up and running locally takes just a handful of commands. Because SEAM is a vanilla JavaScript SPA with no JavaScript bundler, the only build step is compiling Tailwind CSS from css/tailwind-base.css into css/tailwind.css. Once that file exists, the server.js Node.js HTTP server takes care of serving every asset — JavaScript modules, HTML, images, and fonts — with the correct MIME types and an SPA fallback so client-side hash routing works seamlessly.
1

Prerequisites

Before you begin, confirm the following are in place:
  • Node.js 18+ — SEAM’s server.js uses the native node --watch flag (available since Node 18) and ES Module syntax ("type": "module" in package.json). Check your version:
node --version
  • A running backend API — SEAM is a frontend-only application. It expects a REST API at http://localhost:3001/api/v1 by default. Start your backend server before (or alongside) SEAM so that login and data requests succeed.
SEAM’s own HTTP server runs on port 3000. Your backend API must run on port 3001 (or you must update API_BASE in js/config/api.js to match — see Step 6).
2

Clone the repository and install dependencies

Clone the SEAM repository and install the dev dependencies (Tailwind CSS, PostCSS, and nodemon):
git clone https://github.com/TheSerchCp/SEAM.git
cd SEAM
npm install
The package.json declares only devDependencies — there are no runtime npm packages because server.js relies solely on Node.js built-in modules (http, fs, path).
3

Compile Tailwind CSS

SEAM uses Tailwind CSS v4 compiled by a custom PostCSS build script. Run the one-shot build before starting the server:
npm run build:css
This executes build-tailwind.mjs, which reads css/tailwind-base.css, processes it through @tailwindcss/postcss, and writes the output to css/tailwind.css:
build-tailwind.mjs
import postcss from "postcss";
import tailwindPlugin from "@tailwindcss/postcss";
import fs from "fs";
import tailwindConfig from "./tailwind.config.js";

const inputPath = "./css/tailwind-base.css";
const outputPath = "./css/tailwind.css";

async function build() {
  try {
    const input = fs.readFileSync(inputPath, "utf8");
    const result = await postcss([tailwindPlugin(tailwindConfig)]).process(input, { from: inputPath });
    fs.writeFileSync(outputPath, result.css);
    console.log(`✓ CSS compiled successfully to ${outputPath}`);
  } catch (error) {
    console.error("Error compiling CSS:", error.message);
    process.exit(1);
  }
}

build();
During active UI development, run npm run build:css:watch instead. This invokes the Tailwind CLI in --watch mode so the stylesheet rebuilds automatically whenever you change a class in a .js or .html file:
npm run build:css:watch
The underlying command is:
tailwindcss -i ./css/tailwind-base.css -o ./css/tailwind.css --watch
4

Start the development server

Start the Node.js HTTP server that serves the SPA:
npm start
You should see:
Servidor en http://localhost:3000
Directorio raíz: /your/path/to/SEAM
The full list of available scripts is:
ScriptCommandDescription
npm startnode server.jsStart the server once
npm run devnode --watch server.jsStart with Node’s built-in file watcher
npm run dev:watchnode --watch server.jsAlias for dev — same built-in watcher
npm run dev:nodemonnodemon server.jsStart with nodemon (watches server.js and js/**/*.js)
npm run build:cssnode build-tailwind.mjsCompile Tailwind CSS once
npm run build:css:watchtailwindcss … --watchCompile Tailwind CSS in watch mode
Use npm run dev for day-to-day backend work on server.js. Node’s --watch flag restarts the server automatically on file changes without needing an extra package. For more verbose output and debounce control, npm run dev:nodemon uses the nodemon.json config, which watches server.js and all js/**/*.js files with a 500 ms delay.
5

Open SEAM in your browser

Navigate to the application in any modern browser:
http://localhost:3000
The server resolves / to index.html, which bootstraps js/main.js as an ES Module. The router reads the current URL hash and renders the login page at #/login (or redirects to #/home if a valid session already exists in localStorage).
Do not open index.html directly as a file:// URL. Browsers block ES Module cross-origin requests when loading from the filesystem. SEAM must be served over HTTP. Always use http://localhost:3000.
6

Log in and configure the API base URL

Enter your credentials on the login screen. On successful authentication the backend returns a JWT token and sidebarItems; SEAM stores them in localStorage under currentUser and redirects to #/home.If your backend runs on a different host or port, update the single API_BASE constant before starting the server:
js/config/api.js
// Default — backend on localhost:3001
export const API_BASE = 'http://localhost:3001/api/v1';
Change it to point to any backend, for example a remote staging server:
js/config/api.js
export const API_BASE = 'https://api.staging.example.com/api/v1';
Every repository and service module throughout the codebase imports API_BASE from this single file, so one edit propagates everywhere. No rebuild is needed for the JavaScript layer — just save the file, refresh the browser, and the new base URL is in effect.

Build docs developers (and LLMs) love