Update cheatsheets

This commit is contained in:
ivuorinen
2026-01-26 00:24:33 +00:00
parent 2aa4763c61
commit 329616d81f
2 changed files with 42 additions and 1 deletions

View File

@@ -5,7 +5,7 @@ source: https://github.com/tldr-pages/tldr.git
---
# git add
> Adds changed files to the index.
> Stage changed files for a commit.
> More information: <https://git-scm.com/docs/git-add>.
- Stage a file for a commit:

41
tldr/ng-generate Normal file
View File

@@ -0,0 +1,41 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# ng generate
> Generate and/or modify files based on a schematic.
> More information: <https://angular.dev/cli/generate>.
- Generate AI configuration files for Angular project:
`ng {{[g|generate]}} ai-config`
- Create a new service:
`ng {{[g|generate]}} {{[s|service]}} {{service_name}}`
- Generate a new application within the workspace:
`ng {{[g|generate]}} {{[app|application]}} {{app_name}}`
- Create a new class:
`ng {{[g|generate]}} {{[cl|class]}} {{class_name}}`
- Create a new component:
`ng {{[g|generate]}} {{[c|component]}} {{component_name}}`
- Create a new directive:
`ng {{[g|generate]}} {{[d|directive]}} {{directive_name}}`
- Create a new enum:
`ng {{[g|generate]}} {{[e|enum]}} {{enum_name}}`
- Create a new pipe:
`ng {{[g|generate]}} {{[p|pipe]}} {{pipe_name}}`