code: function getByte(array, position, length) {
    const d = position % 8;
    const a = Math.floor(position / 8);
    const de = 8 - d;
    const ef = (position + length) - ((a + 1) * 8);
    let fg = (8 * (a + 2)) - (position + length);
    const dg = ((a + 2) * 8) - position;
    fg = Math.max(0, fg);
    if (a >= array.length) {
      console.warn('ran off the end of the buffer before finding EOI_CODE (end on input code)');
      return EOI_CODE;
    }
    let chunk1 = array[a] & ((2 ** (8 - d)) - 1);
    chunk1 <<= (length - de);
    let chunks = chunk1;
    if (a + 1 < array.length) {
      let chunk2 = array[a + 1] >>> fg;
      chunk2 <<= Math.max(0, (length - dg));
      chunks += chunk2;
    }
    if (ef > 8 && a + 2 < array.length) {
      const hi = ((a + 3) * 8) - (position + length);
      const chunk3 = array[a + 2] >>> hi;
      chunks += chunk3;
    }
    return chunks;
  }
docs: end of information