isTypePrimitive<T> function
Returns true when the static type T is a primitive type.
Implementation
bool isTypePrimitive<T>() => switch (T) {
const (num) ||
const (int) ||
const (double) ||
const (bool) ||
const (String) ||
const (BigInt) ||
const (DateTime) =>
true,
_ => false,
};