You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
annotates a property as a protobuf oneof covering the specified fields.
572
573
573
-
Decorated types reside in `protobuf.roots["decorators"]` using a flat structure (no duplicate names).
574
+
Other notes:
575
+
576
+
* Decorated types reside in `protobuf.roots["decorated"]` using a flat structure, so no duplicate names.
577
+
* Enums are copied to a reflected enum with a generic name on decorator evaluation because referenced enum objects have no runtime name the decorator could use.
578
+
* Default values must be specified as arguments to the decorator instead of using a property initializer for proper prototype behavior.
579
+
* Property names on decorated classes must not be renamed on compile time (i.e. by a minifier) because decorators just receive the original field name as a string.
Copy file name to clipboardExpand all lines: src/mapfield.js
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -108,9 +108,9 @@ MapField.prototype.resolve = function resolve() {
108
108
* @function
109
109
* @param {number} fieldId Field id
110
110
* @param {"int32"|"uint32"|"sint32"|"fixed32"|"sfixed32"|"int64"|"uint64"|"sint64"|"fixed64"|"sfixed64"|"bool"|"string"} fieldKeyType Field key type
111
-
* @param {"double"|"float"|"int32"|"uint32"|"sint32"|"fixed32"|"sfixed32"|"int64"|"uint64"|"sint64"|"fixed64"|"sfixed64"|"bool"|"string"|"bytes"|Object|TConstructor<{}>} fieldValueType Field value type
111
+
* @param {"double"|"float"|"int32"|"uint32"|"sint32"|"fixed32"|"sfixed32"|"int64"|"uint64"|"sint64"|"fixed64"|"sfixed64"|"bool"|"string"|"bytes"|Object|Constructor<{}>} fieldValueType Field value type
112
112
* @returns {FieldDecorator} Decorator function
113
-
* @template T extends { [key: string]: any }
113
+
* @template T extends { [key: string]: number | Long | string | boolean | Uint8Array | Buffer | number[] | Message<{}> }
0 commit comments