1 | {
|
2 | "$schema": "http://json-schema.org/draft-07/schema",
|
3 | "$id": "SchematicsAngularDirective",
|
4 | "title": "Angular Directive Options Schema",
|
5 | "type": "object",
|
6 | "description": "Creates a new, generic directive definition in the given project.",
|
7 | "additionalProperties": false,
|
8 | "properties": {
|
9 | "name": {
|
10 | "type": "string",
|
11 | "description": "The name of the new directive.",
|
12 | "$default": {
|
13 | "$source": "argv",
|
14 | "index": 0
|
15 | },
|
16 | "x-prompt": "What name would you like to use for the directive?"
|
17 | },
|
18 | "path": {
|
19 | "type": "string",
|
20 | "format": "path",
|
21 | "$default": {
|
22 | "$source": "workingDirectory"
|
23 | },
|
24 | "description": "The path at which to create the interface that defines the directive, relative to the workspace root.",
|
25 | "visible": false
|
26 | },
|
27 | "project": {
|
28 | "type": "string",
|
29 | "description": "The name of the project.",
|
30 | "$default": {
|
31 | "$source": "projectName"
|
32 | }
|
33 | },
|
34 | "prefix": {
|
35 | "type": "string",
|
36 | "description": "A prefix to apply to generated selectors.",
|
37 | "alias": "p",
|
38 | "oneOf": [
|
39 | {
|
40 | "maxLength": 0
|
41 | },
|
42 | {
|
43 | "minLength": 1,
|
44 | "format": "html-selector"
|
45 | }
|
46 | ]
|
47 | },
|
48 | "skipTests": {
|
49 | "type": "boolean",
|
50 | "description": "Do not create \"spec.ts\" test files for the new class.",
|
51 | "default": false
|
52 | },
|
53 | "skipImport": {
|
54 | "type": "boolean",
|
55 | "description": "Do not import this directive into the owning NgModule.",
|
56 | "default": false
|
57 | },
|
58 | "selector": {
|
59 | "type": "string",
|
60 | "format": "html-selector",
|
61 | "description": "The HTML selector to use for this directive."
|
62 | },
|
63 | "standalone": {
|
64 | "description": "Whether the generated directive is standalone.",
|
65 | "type": "boolean",
|
66 | "default": true,
|
67 | "x-user-analytics": "ep.ng_standalone"
|
68 | },
|
69 | "flat": {
|
70 | "type": "boolean",
|
71 | "description": "When true (the default), creates the new files at the top level of the current project.",
|
72 | "default": true
|
73 | },
|
74 | "module": {
|
75 | "type": "string",
|
76 | "description": "The declaring NgModule.",
|
77 | "alias": "m"
|
78 | },
|
79 | "export": {
|
80 | "type": "boolean",
|
81 | "default": false,
|
82 | "description": "The declaring NgModule exports this directive."
|
83 | }
|
84 | },
|
85 | "required": ["name", "project"]
|
86 | }
|