```typescript
export function formatBits(value: number, width: number): string {
  if (!Number.isInteger(value) || value < 0) {
    throw new Error("Value must be a non-negative integer.");
  }
  if (width % 4 !== 0 || width > 32) {
    throw new Error("Width must be a positive multiple of four up to 32.");
  }
  if (value >= Math.pow(2, width)) {
    throw new Error("Value does not fit in the specified width.");
  }

  const binary = value.toString(2).padStart(width, '0').split('').reverse();
  const nibbleGroups = [];
  for (let i = 0; i < binary.length; i += 4) {
    nibbleGroups.push(binary.slice(i, i + 4).join(''));
  }
  return nibbleGroups.join(' ');
}
```