Skip to content

Commit 2b2edcb

Browse files
committed
Update index.md
1 parent 5e12a1a commit 2b2edcb

1 file changed

Lines changed: 42 additions & 1 deletion

File tree

docs/en/cli/index.md

Lines changed: 42 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ Here is the list of all available commands before explaining their details:
3939
- `**[help](../cli#help)`**: Shows help on the usage of the ABP CLI.
4040
- `**[cli](../cli#cli)`**: Update or remove ABP CLI.
4141
- `**[new](../cli#new)**`: Generates a new solution based on the ABP [startup templates](../solution-templates/index.md). Use `--modern` to create solutions with the modern template system (React UI).
42-
- `**[new-module](../cli#new-module)**`: Generates a new module based on the given template.
42+
- `**[new-module](../cli#new-module)**`: Generates a new module based on the given template. Use `--modern` to use modern module templates.
4343
- `**[new-package](../cli#new-package)**`: Generates a new package based on the given template.
4444
- `**[update](../cli#update)**`: Automatically updates all ABP related NuGet and NPM packages in a solution.
4545
- `**[clean](../cli#clean)**`: Deletes all `BIN` and `OBJ` folders in the current folder.
@@ -251,6 +251,17 @@ For more samples, go to [ABP CLI Create Solution Samples](new-command-samples.md
251251
- `--legacy`: Generates a legacy solution.
252252
- `trust-version`: Trusts the user's version and does not check if the version exists or not. If the template with the given version is found in the cache, it will be used, otherwise throws an exception.
253253

254+
##### Modern Template Options
255+
256+
The following options apply only when `--modern` is used:
257+
258+
| Option | Description | Templates |
259+
| --- | --- | --- |
260+
| `--shadcn-theme <theme>` | Shadcn/UI color theme. See [Shadcn Theme Values](#shadcn-theme-values). | all `--modern` templates |
261+
| `--admin-password <password>` | Initial admin user password. | all `--modern` templates |
262+
| `--modular` | Generates a modular monolith variant. | `app-nolayers --modern` |
263+
| `--services <list>` | Comma-separated additional microservice names (for example: `Ordering,Shipping`). | `microservice --modern` |
264+
254265
#### Modern Templates
255266

256267
Add `--modern` to any template to use its modern variant. Modern templates use a different template source (shipped with ABP Studio) compared to legacy templates (which use NuGet extension packages). They are **React-first** and have a narrower set of supported options.
@@ -270,6 +281,10 @@ abp new Acme.BookStore --template microservice --modern
270281

271282

272283
> Blazor, Angular, MVC, and MAUI Blazor UI frameworks are **not** supported with `--modern`. The `maui` mobile option is also not supported with `--modern`.
284+
>
285+
> Options that are not supported by a modern template are ignored with a warning in the CLI output.
286+
>
287+
> `--modern` can also be used with `--ready-config-path` and `--solution-history-id`. In these cases, the template in the JSON configuration is mapped to its modern variant.
273288
274289
When using `--template microservice --modern`, the generated solution includes:
275290

@@ -303,6 +318,17 @@ abp new Acme.BookStore --template microservice --modern --database-management-sy
303318
abp new Acme.BookStore --template microservice --modern --mobile react-native
304319
```
305320

321+
##### Shadcn Theme Values
322+
323+
Use `--shadcn-theme <theme>` with `--modern` templates:
324+
325+
- `slate` (default)
326+
- `pink`
327+
- `blue`
328+
- `turquoise`
329+
- `orange`
330+
- `purple`
331+
306332
### new-module
307333

308334
Generates a new module.
@@ -320,6 +346,7 @@ abp new-module Acme.BookStore -t module:ddd
320346
#### options
321347

322348
- `--template` or `-t`: Specifies the template name. Default template name is `module:ddd`, which generates a DDD module. Module templates are provided by the main template, see their own startup template documentation for available modules. `empty:empty` and `module:ddd` template is available for all solution structure.
349+
- `--modern`: Uses the modern variant of the selected module template.
323350
- `--output-folder` or `-o`: Specifies the output folder. Default value is the current directory.
324351
- `--target-solution` or `-ts`: If set, the new module will be added to the given solution. Otherwise the new module will added to the closest solution in the file system. If no solution found, it will throw an error.
325352
- `--solution-folder` or `-sf`: Specifies the target folder in the [Solution Explorer](../studio/solution-explorer.md#folder) virtual folder system.
@@ -332,6 +359,20 @@ abp new-module Acme.BookStore -t module:ddd
332359
- `blazor`: Blazor UI.
333360
- `blazor-server`: Blazor Server UI.
334361

362+
#### Modern Module Templates
363+
364+
Add `--modern` to use the modern module variant:
365+
366+
```bash
367+
abp new-module Acme.BookStore.Orders --modern
368+
abp new-module Acme.BookStore.Orders --modern -t module:ddd
369+
abp new-module Acme.BookStore.Orders --modern -t module:standard
370+
```
371+
372+
When the target solution itself is modern, the modern module variant is selected automatically even if `--modern` is not passed.
373+
374+
Options that are not supported by a modern module template are ignored with a warning in the CLI output.
375+
335376
### new-package
336377

337378
Generates a new package.

0 commit comments

Comments
 (0)