Package proto3-json-serializer (2.0.1)

Interfaces

JSONObject

ToProto3JSONOptions

Functions

fromProto3JSON(type, json)

export declare function fromProto3JSON(type: protobuf.Type, json: JSONValue): protobuf.Message<{}> | null;
Parameters
Name Description
type protobuf.Type
json JSONValue
Returns
Type Description
Message<{}> | null

toProto3JSON(obj, options)

export declare function toProto3JSON(obj: protobuf.Message, options?: ToProto3JSONOptions): JSONValue;
Parameters
Name Description
obj protobuf.Message
options ToProto3JSONOptions
Returns
Type Description
JSONValue

Type Aliases

JSONValue

export type JSONValue = string | number | boolean | null | JSONValue[] | {
    [key: string]: JSONValue;
};