Function boolToByte

  • Converts a boolean to StaticArray.


    • val: bool

      the boolean value to convert

    Returns StaticArray<u8>

    the serialized boolean as a byte in a StaticArray 'byte array'


    The conversion is performed by creating a StaticArray of length 1, where the first byte represents the boolean value. If the value is true, the byte is set to 1, otherwise, it is set to 0.

Generated using TypeDoc