# TS1196: Catch clause variable type annotation must be 'any' or 'unknown' if specified.

> A `catch` variable is annotated with a type other than `any` or `unknown`. Remove the annotation or use `unknown` and narrow it.

## What it means

Anything can be thrown in JavaScript, so a `catch` clause can't promise a specific type for
the caught value. Only `any` and `unknown` are allowed as annotations.

## Example

```ts
try {
  JSON.parse('{');
} catch (e: Error) {
  console.log(e);
}
export {};
```

## How to fix

- Annotate with `unknown` (or leave it out) and narrow: `if (e instanceof Error) { ... }`.

Source: https://ts-r.dev/errors/TS1196/
