bigeasy / packet

Incremental binary parsers and serializers for Node.js.

Home Page:http://bigeasy.github.io/packet

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Allow collapsed nested structures and packed integers.

bigeasy opened this issue · comments

const definition = {
    _header: [{
        type: 4,
        length: 4
    }, 8 ]
}

In the above, instead of creating a _header structure, we just assign a type and length property to the parsed object.