---
title: JSType
framework: javascriptcore
role: symbol
role_heading: Structure
path: javascriptcore/jstype
---

# JSType

Constants that identify the type of a JavaScript value.

## Declaration

```swift
struct JSType
```

## Topics

### Constants

- [kJSTypeUndefined](javascriptcore/kjstypeundefined.md)
- [kJSTypeNull](javascriptcore/kjstypenull.md)
- [kJSTypeBoolean](javascriptcore/kjstypeboolean.md)
- [kJSTypeNumber](javascriptcore/kjstypenumber.md)
- [kJSTypeString](javascriptcore/kjstypestring.md)
- [kJSTypeObject](javascriptcore/kjstypeobject.md)
- [kJSTypeSymbol](javascriptcore/kjstypesymbol.md)

### Initializers

- [init(_:)](javascriptcore/jstype/init(_:).md)
- [init(rawValue:)](javascriptcore/jstype/init(rawvalue:).md)
- [rawValue](javascriptcore/jstype/rawvalue.md)

## Relationships

### Conforms To

- [BitwiseCopyable](swift/bitwisecopyable.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [RawRepresentable](swift/rawrepresentable.md)
- [Sendable](swift/sendable.md)

## See Also

### Testing the Value’s Type

- [JSValueGetType(_:_:)](javascriptcore/jsvaluegettype(_:_:).md)
- [JSValueIsUndefined(_:_:)](javascriptcore/jsvalueisundefined(_:_:).md)
- [JSValueIsNull(_:_:)](javascriptcore/jsvalueisnull(_:_:).md)
- [JSValueIsBoolean(_:_:)](javascriptcore/jsvalueisboolean(_:_:).md)
- [JSValueIsNumber(_:_:)](javascriptcore/jsvalueisnumber(_:_:).md)
- [JSValueIsString(_:_:)](javascriptcore/jsvalueisstring(_:_:).md)
- [JSValueIsSymbol(_:_:)](javascriptcore/jsvalueissymbol(_:_:).md)
- [JSValueIsObject(_:_:)](javascriptcore/jsvalueisobject(_:_:).md)
- [JSValueIsObjectOfClass(_:_:_:)](javascriptcore/jsvalueisobjectofclass(_:_:_:).md)
- [JSValueIsArray(_:_:)](javascriptcore/jsvalueisarray(_:_:).md)
- [JSValueIsDate(_:_:)](javascriptcore/jsvalueisdate(_:_:).md)
- [JSValueGetTypedArrayType(_:_:_:)](javascriptcore/jsvaluegettypedarraytype(_:_:_:).md)
