Skip to content

Commit b43225d

Browse files
committed
docs(proto-loader-gen-types): update option description of proto-loader-gen-types in README.md
1 parent 8499c7b commit b43225d

File tree

1 file changed

+42
-33
lines changed

1 file changed

+42
-33
lines changed

packages/proto-loader/README.md

Lines changed: 42 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -61,44 +61,53 @@ The `proto-loader-gen-types` script distributed with this package can be used to
6161
proto-loader-gen-types.js [options] filenames...
6262

6363
Options:
64-
--help Show help [boolean]
65-
--version Show version number [boolean]
66-
--keepCase Preserve the case of field names
64+
--help Show help [boolean]
65+
--version Show version number [boolean]
66+
--keepCase Preserve the case of field names
6767
[boolean] [default: false]
68-
--longs The type that should be used to output 64 bit integer
69-
values. Can be String, Number[string] [default: "Long"]
70-
--enums The type that should be used to output enum fields. Can
71-
be String [string] [default: "number"]
72-
--bytes The type that should be used to output bytes fields.
73-
Can be String, Array [string] [default: "Buffer"]
74-
--defaults Output default values for omitted fields
68+
--longs The type that should be used to output 64 bit
69+
integer values. Can be String, Number
70+
[string] [default: "Long"]
71+
--enums The type that should be used to output enum fields.
72+
Can be String [string] [default: "number"]
73+
--bytes The type that should be used to output bytes
74+
fields. Can be String, Array
75+
[string] [default: "Buffer"]
76+
--defaults Output default values for omitted fields
7577
[boolean] [default: false]
76-
--arrays Output default values for omitted repeated fields even
77-
if --defaults is not set [boolean] [default: false]
78-
--objects Output default values for omitted message fields even
79-
if --defaults is not set [boolean] [default: false]
80-
--oneofs Output virtual oneof fields set to the present field's
81-
name [boolean] [default: false]
82-
--json Represent Infinity and NaN as strings in float fields.
83-
Also decode google.protobuf.Any automatically
78+
--arrays Output default values for omitted repeated fields
79+
even if --defaults is not set
8480
[boolean] [default: false]
85-
--includeComments Generate doc comments from comments in the original
86-
files [boolean] [default: false]
87-
-I, --includeDirs Directories to search for included files [array]
88-
-O, --outDir Directory in which to output files [string] [required]
89-
--grpcLib The gRPC implementation library that these types will
90-
be used with. If not provided, some types will not be
91-
generated [string]
92-
--inputTemplate Template for mapping input or "permissive" type names
93-
[string] [default: "%s"]
94-
--outputTemplate Template for mapping output or "restricted" type names
95-
[string] [default: "%s__Output"]
96-
--inputBranded Output property for branded type for "permissive"
97-
types with fullName of the Message as its value
81+
--objects Output default values for omitted message fields
82+
even if --defaults is not set
9883
[boolean] [default: false]
99-
--outputBranded Output property for branded type for "restricted"
100-
types with fullName of the Message as its value
84+
--oneofs Output virtual oneof fields set to the present
85+
field's name [boolean] [default: false]
86+
--json Represent Infinity and NaN as strings in float
87+
fields. Also decode google.protobuf.Any
88+
automatically [boolean] [default: false]
89+
--includeComments Generate doc comments from comments in the original
90+
files [boolean] [default: false]
91+
-I, --includeDirs Directories to search for included files [array]
92+
-O, --outDir Directory in which to output files
93+
[string] [required]
94+
--grpcLib The gRPC implementation library that these types
95+
will be used with. If not provided, some types will
96+
not be generated [string]
97+
--inputTemplate Template for mapping input or "permissive" type
98+
names [string] [default: "%s"]
99+
--outputTemplate Template for mapping output or "restricted" type
100+
names [string] [default: "%s__Output"]
101+
--inputBranded Output property for branded type for "permissive"
102+
types with fullName of the Message as its value
101103
[boolean] [default: false]
104+
--outputBranded Output property for branded type for "restricted"
105+
types with fullName of the Message as its value
106+
[boolean] [default: false]
107+
--targetFileExtension File extension for generated files. Defaults to .ts
108+
[string] [default: ".ts"]
109+
--importFileExtension File extension for import specifiers in generated
110+
code. Defaults to none (omitted) [string]
102111
```
103112

104113
### Example Usage

0 commit comments

Comments
 (0)