Skip to content

How to serialize object make the output the same as SerializeAsString() method of C++  #167

Open
@DinoStray

Description

@DinoStray

In C++, I can call protobuf_object.SerializeAsString().
Which method is the same as above in nodejs?
The following code is not correct.

            let out = pbObj.serializeBinary();
            let serializeStr = Buffer.from(out).toString();

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions