<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [@csstools/css-tokenizer](./css-tokenizer.md) &gt; [mirrorVariant](./css-tokenizer.mirrorvariant.md)

## mirrorVariant() function

Get the mirror variant of a given token

**Signature:**

```typescript
export declare function mirrorVariant(token: CSSToken): CSSToken | null;
```

## Parameters

<table><thead><tr><th>

Parameter


</th><th>

Type


</th><th>

Description


</th></tr></thead>
<tbody><tr><td>

token


</td><td>

[CSSToken](./css-tokenizer.csstoken.md)


</td><td>


</td></tr>
</tbody></table>

**Returns:**

[CSSToken](./css-tokenizer.csstoken.md) \| null

## Example


```js
const input = [TokenType.OpenParen, '(', 0, 1, undefined];
const output = mirrorVariant(input);

console.log(output); // [TokenType.CloseParen, ')', -1, -1, undefined]
```

