Skip to content

Commit 8a6da5d

Browse files
committed
docs: document saas-builder setup and conventions
1 parent ed7c7f2 commit 8a6da5d

2 files changed

Lines changed: 37 additions & 4 deletions

File tree

README.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -299,6 +299,35 @@ After defining the environment variables in your GitHub Actions, your localizati
299299
└── tsconfig.json # TypeScript configuration
300300
```
301301

302+
### Getting started with the SaaS Boilerplate skill
303+
304+
> [!WARNING]
305+
> Use the `saas-builder` skill only when you want to start a new project. The skill clones and sets up a new boilerplate project for you.
306+
307+
If you want an AI coding agent to clone, verify, and build your SaaS on top of this boilerplate, install the `saas-builder` skill:
308+
309+
```shell
310+
npx skills add ixartz/saas-boilerplate
311+
```
312+
313+
The skill works with Codex, Claude Code, and other agents that support the Agent Skills standard.
314+
315+
Be as detailed as possible when describing your SaaS idea. The more context you provide about the product, users, features, and requirements, the better the AI agent can build the right application.
316+
317+
In Codex, run:
318+
319+
```text
320+
codex
321+
$saas-builder Build a SaaS for <your idea>.
322+
```
323+
324+
In Claude Code, run:
325+
326+
```text
327+
claude
328+
/saas-builder Build a SaaS for <your idea>.
329+
```
330+
302331
### Customization
303332

304333
You can easily configure Next.js SaaS Boilerplate by searching the entire project for `FIXME:` to make quick customization. Here are some of the most important files to customize:

skills/saas-builder/SKILL.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ cd <target-directory>
1919
npm install
2020
```
2121

22+
Users usually run `npx skills add ixartz/saas-boilerplate` from a parent/root directory; it creates `.agents/` there and clones the boilerplate into `<target-directory>`. Since the app is one level below the agent's initial cwd, `cd <target-directory>` before reading app files or running project commands, and confirm `package.json`, `src/`, and `skills/` exist.
23+
2224
Then verify the baseline:
2325

2426
```bash
@@ -32,9 +34,9 @@ Setup and verification commands are hard gates. Do not continue to mapping or im
3234

3335
- Use the verified clone as the source of truth. Inspect current files before making claims or edits.
3436
- Keep changes minimal. Do not reformat unrelated files.
35-
- Preserve `src/components/DemoBadge.tsx` and its layout usage.
37+
- Preserve `src/components/DemoBadge.tsx` and its layout usage. Also preserve `src/app/[locale]/(auth)/dashboard/page.tsx`.
3638
- Use marketing routes only for promotional content.
37-
- Build product workflows as authenticated dashboard pages: CRUD, data entry, tools, and customer-specific views.
39+
- Build product workflows as dedicated authenticated dashboard feature pages, not in the dashboard index: use `src/app/[locale]/(auth)/dashboard/<feature>/page.tsx` for CRUD, data entry, tools, and customer-specific views.
3840

3941
## Project Conventions
4042

@@ -43,6 +45,8 @@ Setup and verification commands are hard gates. Do not continue to mapping or im
4345
- Put user-visible copy in every supported locale file.
4446
- Prefer existing Clerk account and organization features before custom auth flows.
4547
- Follow nearby style and import conventions.
48+
- Run `npm run db:generate` whenever `src/models/Schema.ts` changes.
49+
- Make new components visually polished and consistent with the current UI: reuse existing Shadcn/Radix primitives, Tailwind tokens, spacing, typography, states, and responsive patterns before introducing new visual treatments.
4650
- React Compiler is enabled, so don't add `useMemo` or `useCallback`.
4751

4852
## MVP Scope
@@ -68,13 +72,13 @@ Use these as starting search targets:
6872
- Locales and i18n: `src/locales/en.json`, `src/locales/fr.json`
6973
- Database schema: `src/models/Schema.ts`
7074
- Marketing: `src/app/[locale]/(marketing)`
71-
- User dashboard: `src/app/[locale]/(auth)/dashboard/`
75+
- User dashboard overview: `src/app/[locale]/(auth)/dashboard/page.tsx`
7276
- Product feature pages: `src/app/[locale]/(auth)/dashboard/<feature>/page.tsx`
7377

7478
## Mapping Heuristics
7579

7680
- Use a tenant only for the top-level organization a user can join and switch between, where membership, permissions, billing, collaboration, or data isolation are scoped.
77-
- Model sub-entities as organization-owned Drizzle records scoped by `organizationId`; user-owned records use `userId`.
81+
- Model sub-entities as Drizzle records scoped by a single `ownerId` field.
7882
- Prefer existing Clerk and boilerplate features before custom flows.
7983

8084
## Workflow

0 commit comments

Comments
 (0)