UNPKG

proto3-json-serializer

Version:

Support for proto3 JSON serialiazation/deserialization for protobuf.js

11 lines (10 loc) 373 B
import * as protobuf from 'protobufjs'; import { FromObjectValue } from './types'; export interface Duration { seconds: number; nanos?: number; } export declare function googleProtobufDurationToProto3JSON(obj: protobuf.Message & Duration): string; export declare function googleProtobufDurationFromProto3JSON(json: string): { [key: string]: FromObjectValue; };