0.1.1 • Published 7 years ago

ioant-proto v0.1.1

Weekly downloads
1
License
MIT
Repository
github
Last release
7 years ago

npm-package-proto

This package is used for loading proto files. It also contains some convenience functions for handling proto messages.

How to use

Load the module and set the path to the proto file

var Proto = require('ioant-proto');
Proto.setup("proto/messages.proto");

Get a proto message based on its corresponding message_type

// 1 is messag_type for BootInfo message
message = Proto.getProtoMessage(1);
message.reboot_reason = "I crashed";