Package proto3-json-serializer (1.1.0)

Stay organized with collections Save and categorize content based on your preferences.

Interfaces

JSONObject

ToProto3JSONOptions

Functions

fromProto3JSON(type, json)

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

toProto3JSON(obj, options)

export declare function toProto3JSON(obj: protobuf.Message, options?: ToProto3JSONOptions): JSONValue;
Parameters
NameDescription
objprotobuf.Message
optionsToProto3JSONOptions
Returns
TypeDescription
JSONValue

Type Aliases

JSONValue

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