Skip to content

Commit 59a1b73

Browse files
committed
Update Project Structure
1 parent 054d51c commit 59a1b73

File tree

5 files changed

+181
-148
lines changed

5 files changed

+181
-148
lines changed

content/docs/templates/next-rsc.mdx

Lines changed: 39 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -118,36 +118,46 @@ This template uses a consistent architecture across all environments where the .
118118
## Project Structure
119119

120120
```
121-
MyApp/ # Main ASP.NET Core host
122-
├── Configure.*.cs # Modular startup configuration
123-
├── Program.cs # Application entry point
124-
└── wwwroot/ # Static files (production)
125-
126-
MyApp.Client/ # Next.js frontend application
127-
├── app/ # Next.js App Router pages
128-
├── components/ # React components
129-
├── lib/ # Utilities and helpers
130-
├── public/ # Static assets
131-
└── dist/ # Build output (production)
132-
133-
MyApp.ServiceInterface/ # Service implementations
134-
├── MyServices.cs # Example services
135-
└── Data/ # EF Core DbContext
136-
137-
MyApp.ServiceModel/ # DTOs and service contracts
138-
├── Bookings.cs # AutoQuery CRUD example
139-
└── Hello.cs # Example service contract
140-
141-
MyApp.Tests/ # Integration and unit tests
142-
143-
config/ # Deployment configuration
144-
└── deploy.yml # Kamal deployment settings
145-
146-
.github/ # GitHub Actions workflows
121+
MyApp/ # .NET Backend (hosts both .NET and Next.js)
122+
├── Configure.*.cs # Modular startup configuration
123+
├── Migrations/ # EF Core Identity migrations + OrmLite app migrations
124+
├── Pages/ # Identity Auth Razor Pages
125+
└── wwwroot/ # Production static files (from MyApp.Client/dist)
126+
127+
MyApp.Client/ # React Frontend
128+
├── app/ # Next.js App Router pages
129+
├── components/ # React components
130+
├── lib/ # Utilities and helpers
131+
│ ├── dtos.ts # Auto-generated from C# (via `npm run dtos`)
132+
│ ├── gateway.ts # ServiceStack JsonServiceClient
133+
│ └── utils.ts # Utility functions
134+
├── public/ # Static assets
135+
├── dist/ # Build output (production)
136+
├── styles/ # Tailwind CSS styles
137+
└── next.config.mjs # Next.js config for dev mode
138+
139+
MyApp.ServiceModel/ # DTOs & API contracts
140+
├── *.cs # C# Request/Response DTOs
141+
├── api.d.ts # TypeScript data models Schema
142+
└── *.d.ts # TypeScript data models for okai code generation
143+
144+
MyApp.ServiceInterface/ # Service implementations
145+
├── Data/ # EF Core DbContext and Identity models
146+
└── *Services.cs # ServiceStack service implementations
147+
148+
MyApp.Tests/ # .NET tests (NUnit)
149+
├── IntegrationTest.cs # API integration tests
150+
└── MigrationTasks.cs # Migration task runner
151+
152+
Dockerfile # Custom .NET + Next.js Dockerfile
153+
entrypoint.sh # Coordinated .NET and Node process management
154+
config/
155+
└── deploy.yml # Kamal deployment settings
156+
.github/
147157
└── workflows/
148-
├── build.yml # CI build and test
149-
├── build-container.yml # Container image build
150-
└── release.yml # Production deployment with Kamal
158+
├── build.yml # CI build and test
159+
├── build-container.yml # Container image build
160+
└── release.yml # Production deployment with Kamal
151161
```
152162

153163
## Development Workflow

content/docs/templates/next-static.mdx

Lines changed: 37 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -115,37 +115,44 @@ This template uses a hybrid architecture that optimizes for both development spe
115115
## Project Structure
116116

117117
```
118-
MyApp/ # Main ASP.NET Core host
119-
├── Configure.*.cs # Modular startup configuration
120-
├── Program.cs # Application entry point
121-
└── wwwroot/ # Static files (production)
122-
123-
MyApp.Client/ # Next.js frontend application
124-
├── app/ # Next.js App Router pages
125-
├── components/ # React components
126-
├── lib/ # Utilities and helpers
127-
├── public/ # Static assets
128-
├── dist/ # Build output (production)
129-
└── styles/ # Tailwind CSS styles
130-
131-
MyApp.ServiceInterface/ # Service implementations
132-
├── MyServices.cs # Example services
133-
└── Data/ # EF Core DbContext
134-
135-
MyApp.ServiceModel/ # DTOs and service contracts
136-
├── Bookings.cs # AutoQuery CRUD example
137-
└── Hello.cs # Example service contract
138-
139-
MyApp.Tests/ # Integration and unit tests
140-
141-
config/ # Deployment configuration
142-
└── deploy.yml # Kamal deployment settings
143-
144-
.github/ # GitHub Actions workflows
118+
MyApp/ # .NET Backend (hosts both .NET and Next.js)
119+
├── Configure.*.cs # Modular startup configuration
120+
├── Migrations/ # EF Core Identity migrations + OrmLite app migrations
121+
├── Pages/ # Identity Auth Razor Pages
122+
└── wwwroot/ # Production static files (from MyApp.Client/dist)
123+
124+
MyApp.Client/ # React Frontend
125+
├── app/ # Next.js App Router pages
126+
├── components/ # React components
127+
├── lib/ # Utilities and helpers
128+
│ ├── dtos.ts # Auto-generated from C# (via `npm run dtos`)
129+
│ ├── gateway.ts # ServiceStack JsonServiceClient
130+
│ └── utils.ts # Utility functions
131+
├── public/ # Static assets
132+
├── dist/ # Build output (production)
133+
├── styles/ # Tailwind CSS styles
134+
└── next.config.mjs # Next.js config for dev mode
135+
136+
MyApp.ServiceModel/ # DTOs & API contracts
137+
├── *.cs # C# Request/Response DTOs
138+
├── api.d.ts # TypeScript data models Schema
139+
└── *.d.ts # TypeScript data models for okai code generation
140+
141+
MyApp.ServiceInterface/ # Service implementations
142+
├── Data/ # EF Core DbContext and Identity models
143+
└── *Services.cs # ServiceStack service implementations
144+
145+
MyApp.Tests/ # .NET tests (NUnit)
146+
├── IntegrationTest.cs # API integration tests
147+
└── MigrationTasks.cs # Migration task runner
148+
149+
config/
150+
└── deploy.yml # Kamal deployment settings
151+
.github/
145152
└── workflows/
146-
├── build.yml # CI build and test
147-
├── build-container.yml # Container image build
148-
└── release.yml # Production deployment with Kamal
153+
├── build.yml # CI build and test
154+
├── build-container.yml # Container image build
155+
└── release.yml # Production deployment with Kamal
149156
```
150157

151158
## Development Workflow

content/docs/templates/nextjs.mdx

Lines changed: 37 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -138,37 +138,44 @@ This template uses a hybrid architecture that differs between development and pr
138138
## Project Structure
139139

140140
```
141-
MyApp/ # Main ASP.NET Core host
142-
├── Configure.*.cs # Modular startup configuration
143-
├── Program.cs # Application entry point
144-
└── wwwroot/ # Static files (production)
145-
146-
MyApp.Client/ # Next.js frontend application
147-
├── app/ # Next.js App Router pages
148-
├── components/ # React components
149-
├── lib/ # Utilities and helpers
150-
├── public/ # Static assets
151-
├── dist/ # Build output (production)
152-
└── styles/ # Tailwind CSS styles
153-
154-
MyApp.ServiceInterface/ # Service implementations
155-
├── MyServices.cs # Example services
156-
└── Data/ # EF Core DbContext
157-
158-
MyApp.ServiceModel/ # DTOs and service contracts
159-
├── Bookings.cs # AutoQuery CRUD example
160-
└── Hello.cs # Example service contract
161-
162-
MyApp.Tests/ # Integration and unit tests
163-
164-
config/ # Deployment configuration
165-
└── deploy.yml # Kamal deployment settings
166-
167-
.github/ # GitHub Actions workflows
141+
MyApp/ # .NET Backend (hosts both .NET and Next.js)
142+
├── Configure.*.cs # Modular startup configuration
143+
├── Migrations/ # EF Core Identity migrations + OrmLite app migrations
144+
├── Pages/ # Identity Auth Razor Pages
145+
└── wwwroot/ # Production static files (from MyApp.Client/dist)
146+
147+
MyApp.Client/ # React Frontend
148+
├── app/ # Next.js App Router pages
149+
├── components/ # React components
150+
├── lib/ # Utilities and helpers
151+
│ ├── dtos.ts # Auto-generated from C# (via `npm run dtos`)
152+
│ ├── gateway.ts # ServiceStack JsonServiceClient
153+
│ └── utils.ts # Utility functions
154+
├── public/ # Static assets
155+
├── dist/ # Build output (production)
156+
├── styles/ # Tailwind CSS styles
157+
└── next.config.mjs # Next.js config for dev mode
158+
159+
MyApp.ServiceModel/ # DTOs & API contracts
160+
├── *.cs # C# Request/Response DTOs
161+
├── api.d.ts # TypeScript data models Schema
162+
└── *.d.ts # TypeScript data models for okai code generation
163+
164+
MyApp.ServiceInterface/ # Service implementations
165+
├── Data/ # EF Core DbContext and Identity models
166+
└── *Services.cs # ServiceStack service implementations
167+
168+
MyApp.Tests/ # .NET tests (NUnit)
169+
├── IntegrationTest.cs # API integration tests
170+
└── MigrationTasks.cs # Migration task runner
171+
172+
config/
173+
└── deploy.yml # Kamal deployment settings
174+
.github/
168175
└── workflows/
169-
├── build.yml # CI build and test
170-
├── build-container.yml # Container image build
171-
└── release.yml # Production deployment with Kamal
176+
├── build.yml # CI build and test
177+
├── build-container.yml # Container image build
178+
└── release.yml # Production deployment with Kamal
172179
```
173180

174181
## Example Pages

content/docs/templates/react-spa.mdx

Lines changed: 33 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -186,39 +186,42 @@ Built-in theme support:
186186
## Project Structure
187187

188188
```
189-
MyApp/ # Main ASP.NET Core host
190-
├── Configure.*.cs # Modular startup configuration
191-
├── Program.cs # Application entry point
192-
└── wwwroot/ # Static files (production)
189+
MyApp/ # .NET Backend (hosts both .NET and Vite React)
190+
├── Configure.*.cs # Modular startup configuration
191+
├── Migrations/ # EF Core Identity migrations + OrmLite app migrations
192+
├── Pages/ # Identity Auth Razor Pages
193+
└── wwwroot/ # Production static files (from MyApp.Client/dist)
193194
194-
MyApp.Client/ # Vite React SPA frontend
195+
MyApp.Client/ # React Frontend
195196
├── src/
196-
│ ├── pages/ # React Router pages
197-
│ ├── components/ # React components
198-
│ ├── lib/ # Utilities and helpers
199-
│ └── styles/ # Tailwind CSS styles
200-
├── public/ # Static assets
201-
├── dist/ # Build output (production)
202-
└── vite.config.ts # Vite configuration
203-
204-
MyApp.ServiceInterface/ # Service implementations
205-
├── MyServices.cs # Example services
206-
└── Data/ # EF Core DbContext
207-
208-
MyApp.ServiceModel/ # DTOs and service contracts
209-
├── Bookings.cs # AutoQuery CRUD example
210-
└── Hello.cs # Example service contract
211-
212-
MyApp.Tests/ # Integration and unit tests
213-
214-
config/ # Deployment configuration
215-
└── deploy.yml # Kamal deployment settings
216-
217-
.github/ # GitHub Actions workflows
197+
│ ├── lib/
198+
│ │ ├── dtos.ts # Auto-generated from C# (via `npm run dtos`)
199+
│ │ ├── gateway.ts # ServiceStack JsonServiceClient
200+
│ │ └── utils.ts # Utility functions
201+
│ ├── components/ # React components
202+
│ └── styles/ # Tailwind CSS
203+
└── vite.config.ts # Vite config for dev mode
204+
205+
MyApp.ServiceModel/ # DTOs & API contracts
206+
├── *.cs # C# Request/Response DTOs
207+
├── api.d.ts # TypeScript data models Schema
208+
└── *.d.ts # TypeScript data models for okai code generation
209+
210+
MyApp.ServiceInterface/ # Service implementations
211+
├── Data/ # EF Core DbContext and Identity models
212+
└── *Services.cs # ServiceStack service implementations
213+
214+
MyApp.Tests/ # .NET tests (NUnit)
215+
├── IntegrationTest.cs # API integration tests
216+
└── MigrationTasks.cs # Migration task runner
217+
218+
config/
219+
└── deploy.yml # Kamal deployment settings
220+
.github/
218221
└── workflows/
219-
├── build.yml # CI build and test
220-
├── build-container.yml # Container image build
221-
└── release.yml # Production deployment with Kamal
222+
├── build.yml # CI build and test
223+
├── build-container.yml # Container image build
224+
└── release.yml # Production deployment with Kamal
222225
```
223226

224227
## Example Pages

content/docs/templates/react-static.mdx

Lines changed: 35 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -115,36 +115,42 @@ dotnet watch
115115
## Project Structure
116116

117117
```
118-
├── MyApp/ # .NET Backend
119-
│ ├── Configure.*.cs # Modular AppHost configuration
120-
│ ├── Migrations/ # EF Core & OrmLite migrations
121-
│ ├── Program.cs # Application entry point
122-
│ └── wwwroot/ # Static files (production build)
123-
124-
├── MyApp.Client/ # React Frontend
125-
│ ├── src/
126-
│ │ ├── components/ # React components
127-
│ │ ├── lib/
128-
│ │ │ ├── dtos.ts # Auto-generated TypeScript DTOs
129-
│ │ │ ├── gateway.ts # ServiceStack API client
130-
│ │ │ └── utils.ts # Utility functions
131-
│ │ ├── styles/
132-
│ │ │ └── index.css # Tailwind CSS styles
133-
│ │ ├── App.tsx # Main App component
134-
│ │ └── main.tsx # Application entry point
135-
│ ├── vite.config.ts # Vite configuration
136-
│ └── package.json # NPM dependencies
137-
138-
├── MyApp.ServiceInterface/ # Service implementations
139-
├── MyApp.ServiceModel/ # DTOs & API definitions
140-
├── MyApp.Tests/ # Integration & unit tests
141-
└── config/
142-
│ └── deploy.yml # Kamal deployment configuration
143-
│──.github/ # GitHub Actions workflows
118+
MyApp/ # .NET Backend (hosts both .NET and Vite React)
119+
├── Configure.*.cs # Modular startup configuration
120+
├── Migrations/ # EF Core Identity migrations + OrmLite app migrations
121+
├── Pages/ # Identity Auth Razor Pages
122+
└── wwwroot/ # Production static files (from MyApp.Client/dist)
123+
124+
MyApp.Client/ # React Frontend
125+
├── src/
126+
│ ├── lib/
127+
│ │ ├── dtos.ts # Auto-generated from C# (via `npm run dtos`)
128+
│ │ ├── gateway.ts # ServiceStack JsonServiceClient
129+
│ │ └── utils.ts # Utility functions
130+
│ ├── components/ # React components
131+
│ └── styles/ # Tailwind CSS
132+
└── vite.config.ts # Vite config for dev mode
133+
134+
MyApp.ServiceModel/ # DTOs & API contracts
135+
├── *.cs # C# Request/Response DTOs
136+
├── api.d.ts # TypeScript data models Schema
137+
└── *.d.ts # TypeScript data models for okai code generation
138+
139+
MyApp.ServiceInterface/ # Service implementations
140+
├── Data/ # EF Core DbContext and Identity models
141+
└── *Services.cs # ServiceStack service implementations
142+
143+
MyApp.Tests/ # .NET tests (NUnit)
144+
├── IntegrationTest.cs # API integration tests
145+
└── MigrationTasks.cs # Migration task runner
146+
147+
config/
148+
└── deploy.yml # Kamal deployment settings
149+
.github/
144150
└── workflows/
145-
├── build.yml # CI build and test
146-
├── build-container.yml # Container image build
147-
└── release.yml # Production deployment with Kamal
151+
├── build.yml # CI build and test
152+
├── build-container.yml # Container image build
153+
└── release.yml # Production deployment with Kamal
148154
```
149155

150156
## Development Workflow

0 commit comments

Comments
 (0)