Typedefs, or type definitions, allow you to define how input and output types interact with eachother and the editor. These are the types that allow connections to be made between node inputs and outputs.


A typedef.json can be stored anywhere within a nodepack or nodes' directory. Every typedef.json may contain one or many definitions.

Here is an example for the typedef.json used by the "xible.flow" type.

{  "xible.flow": {        // the name of your type as used in your inputs/outputs    "color": "gold",     // the color of the type within the editor    "extends": "object"  // other types this type extends  }}

If you attempt to use this code snippet, be sure to remove the comments (starting with // ...), as the JSON specification does not allow them.


The color value specifies the color visible in the editor on any inputs or outputs of this type. Only named colors (of which a comprehensive list can be found on the W3C site) and hexadecimal colors are allowed.


The extends keyword allows you to define that the base type extends another type. This allows for users to connect outputs of this base type, to an input anywhere within the extends chain.

It is important to realize that this does not work the other way around. An output in the extends chain of an input cannot be connected to that input.