Determines if the given type is a primitive type.

  • Parameters

    • Optionaltype: string

      The type to check.

    Returns type is "string" | "number" | "integer" | "boolean"

    True if the type is a primitive type.