Here is the list of JavaScript special characters for using in JavaScript strings and their meanings.
Character | Description |
---|---|
\0 | Null |
\b | Backspace |
\f | Form feed |
\n | New line |
\r | Carriage return |
\t | Tab |
\v | Vertical tab |
\' | Single quote |
\" | Double quote |
\\ | Backslash |
\XXX | The Latin-1 encoding character specified by three octal digits from 0 to 377 |
\xXX | The Latin-1 encoding character specified by two hexadecimal digits from 00 to FF |
\uXXXX | The Unicode character specified by four hexadecimal digits |
\u{XXXXX} | Unicode code point escapes |