ts-proto 1.92.0 → 1.92.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/README.markdown +3 -3
- package/build/main.js +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
## [1.92.1](https://github.com/stephenh/ts-proto/compare/v1.92.0...v1.92.1) (2021-12-02)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* Respect stringEnums option in wrap function ([#420](https://github.com/stephenh/ts-proto/issues/420)) ([7adf90c](https://github.com/stephenh/ts-proto/commit/7adf90c23c46950bcf457b317764393ff4af2bf2))
|
|
7
|
+
|
|
1
8
|
# [1.92.0](https://github.com/stephenh/ts-proto/compare/v1.91.0...v1.92.0) (2021-11-28)
|
|
2
9
|
|
|
3
10
|
|
package/README.markdown
CHANGED
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
- [Well-Known Types](#well-known-types)
|
|
27
27
|
- [Wrapper Types](#wrapper-types)
|
|
28
28
|
- [JSON Types (Struct Types)](#json-types-struct-types)
|
|
29
|
-
- [
|
|
29
|
+
- [Timestamp](#timestamp)
|
|
30
30
|
- [Wrapper Types](#wrapper-types)
|
|
31
31
|
- [Number Types](#number-types)
|
|
32
32
|
- [Current Status of Optional Values](#current-status-of-optional-values)
|
|
@@ -329,7 +329,7 @@ Generated code will be placed in the Gradle build directory.
|
|
|
329
329
|
|
|
330
330
|
Note that `addGrpcMetadata`, `addNestjsRestParameter` and `returnObservable` will still be false.
|
|
331
331
|
|
|
332
|
-
- With `--ts_proto_opt=useDate=false`, fields of type `google.protobuf.Timestamp` will not be mapped to type `Date` in the generated types. See [
|
|
332
|
+
- With `--ts_proto_opt=useDate=false`, fields of type `google.protobuf.Timestamp` will not be mapped to type `Date` in the generated types. See [Timestamp](#timestamp) for more details.
|
|
333
333
|
|
|
334
334
|
- With `--ts_proto_opt=outputSchema=true`, meta typings will be generated that can later be used in other code generators.
|
|
335
335
|
|
|
@@ -337,7 +337,7 @@ Generated code will be placed in the Gradle build directory.
|
|
|
337
337
|
|
|
338
338
|
- With `--ts_proto_opt=outputServices=grpc-js`, ts-proto will output service definitions and server / client stubs in [grpc-js](https://github.com/grpc/grpc-node/tree/master/packages/grpc-js) format.
|
|
339
339
|
|
|
340
|
-
- With `--ts_proto_opt=outputServices=generic-definitions`, ts-proto will output generic (framework-agnostic) service definitions.
|
|
340
|
+
- With `--ts_proto_opt=outputServices=generic-definitions`, ts-proto will output generic (framework-agnostic) service definitions. These definitions contain descriptors for each method with links to request and response types, which allows to generate server and client stubs at runtime, and also generate strong types for them at compile time. An example of a library that uses this approach is [nice-grpc](https://github.com/deeplay-io/nice-grpc).
|
|
341
341
|
|
|
342
342
|
- With `--ts_proto_opt=outputServices=false`, or `=none`, ts-proto will output NO service definitions.
|
|
343
343
|
|
package/build/main.js
CHANGED
|
@@ -1184,7 +1184,7 @@ function generateWrap(fullProtoTypeName) {
|
|
|
1184
1184
|
if (types_1.isAnyValueTypeName(fullProtoTypeName)) {
|
|
1185
1185
|
chunks.push(ts_poet_1.code `wrap(value: any): Value {
|
|
1186
1186
|
if (value === null) {
|
|
1187
|
-
return {nullValue:
|
|
1187
|
+
return {nullValue: NullValue.NULL_VALUE} as Value;
|
|
1188
1188
|
} else if (typeof value === 'boolean') {
|
|
1189
1189
|
return {boolValue: value} as Value;
|
|
1190
1190
|
} else if (typeof value === 'number') {
|