# TS1127: Invalid character.

> The source contains a character that cannot appear there, such as a stray symbol or an escape that produces an invalid identifier character.

## What it means

The lexer found a character that isn't valid in TypeScript source at that position. Common
causes are characters pasted from documents (smart quotes, symbols) and `\u` escapes inside an
identifier that produce a character identifiers can't contain, such as a space.

## Example

```ts
const x\u0020y = 1;
export {};
```

## How to fix

- Delete or replace the character; retype quotes and operators by hand if the code was pasted.
- Inside identifiers, only use escapes for letters, digits, `$` and `_`.

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