51 lines
1.3 KiB
JSON
51 lines
1.3 KiB
JSON
{
|
|
"$schema": "https://json-schema.org/schema",
|
|
"$id": "Library",
|
|
"title": "Create a NestJS Library for Nx",
|
|
"description": "Create a NestJS Library for Nx.",
|
|
"type": "object",
|
|
"properties": {
|
|
"project": {
|
|
"description": "The project in which to place the library.",
|
|
"type": "string",
|
|
"alias": "p",
|
|
"x-prompt": "Which project to scaffold?",
|
|
"x-dropdown": "projects"
|
|
},
|
|
"type": {
|
|
"description": "The library type that becomes directory where the library is placed.",
|
|
"type": "string",
|
|
"alias": "type",
|
|
"$default": {
|
|
"$source": "argv",
|
|
"index": 0
|
|
},
|
|
"x-prompt": {
|
|
"message": "Which type of library would you like to generate?",
|
|
"type": "list",
|
|
"items": [
|
|
{
|
|
"value": "module",
|
|
"label": "Application module"
|
|
},
|
|
{
|
|
"value": "feature",
|
|
"label": "Feature module"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"name": {
|
|
"description": "Library name.",
|
|
"pattern": "(?:^@[a-zA-Z0-9-*~][a-zA-Z0-9-*._~]*\\/[a-zA-Z0-9-~][a-zA-Z0-9-._~]*|^[a-zA-Z][^:]*)$",
|
|
"type": "string",
|
|
"$default": {
|
|
"$source": "argv",
|
|
"index": 1
|
|
},
|
|
"x-prompt": "What name would you like to use?"
|
|
}
|
|
},
|
|
"required": ["type", "name"]
|
|
}
|