> For the complete documentation index, see [llms.txt](https://typesafe.gitbook.io/road-to-typescript/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://typesafe.gitbook.io/road-to-typescript/flow-equivalence/toc-propertytype.md).

# $PropertyType\<T, k>

## Description

In Flow, a [$PropertyType](https://flow.org/en/docs/types/utilities/#toc-propertytype) is the type at a given key `k`. As of Flow v0.36.0, `k` must be a literal string.

Flow Example ([playground](https://flow.org/try/#0PTAEAEDMBsHsHcBQAXAngBwKagAqYE4DOsAdqALygDeiooJAhgLaYBcohy+AliQOYAaWqAZ829AK5MARgSF10DfJhLJ2eIqUQBfANyJEAY1Kd6meADlm4gCQ58sLPjQAVDJgA8G4iQGgA5Iws-gB8FAEAstyGABYMmNCgAFIMhgDWPv76xiSmJOYAgmLsdg5Oru5eBD5+-qKYoeEArAAM2SbIZvA4SipqoKWOBBVYVZq+AYrKqo2U-kmw2CnpmbpAA))

```javascript
// @flow
type Person = {
  name: string,
  age: number,
  parent: Person
};

const newName: $PropertyType<Person, 'name'> = 'Michael Jackson';
const newAge: $PropertyType<Person, 'age'> = 50;
const newParent: $PropertyType<Person, 'parent'> = 'Joe Jackson';
```

Typescript equivalent of `$PropertyType<T, k>`([playground](https://agentcooper.github.io/typescript-play/#code/C4TwDgpgBAChBOBnA9gOygXigbwFBSlQEMBbCALikWHgEtUBzAGnyiIYsIFcSAjBFgTBF4EVMEpwkaXAF8A3LlyhIUAKIAPGkQDGwACrgIAHn1MoAaQB8mS1AhaxAE0RQA1hBDIAZlH1QAfj8AbQsAXShKVAgANwR5KCUdNGpCCAB3ADlSTk1tPUNIYykUVHMAcmIycpsscoBZWh0ACyIIABsoACldN1LyxWTUVOj0gEEOSjz4XQMjYoRSivYIGtsAVgAGQZTgNPSYETEJdS0ZgvmStArhUXE1uq7kaB6dPrQBqAB6L-V4eGQ8CAA))

```typescript
type Person = {
  name: string,
  age: number,
  parent: Person
};

type PropertyType<T, K> = K extends keyof T ? T[K] : never;

const newName: PropertyType<Person, 'name'> = 'Michael Jackson';
const newAge: PropertyType<Person, 'age'> = 50;
const newParent: PropertyType<Person, 'parent'> = 'Joe Jackson'; // Error
```
