src/content/docs/linter/rules/no-unused-template-literal.mdx
import { Tabs, TabItem } from '@astrojs/starlight/components';
<Tabs> <TabItem label="TypeScript and TSX" icon="seti:typescript"> ## Summary - Rule available since: `v1.0.0` - Diagnostic Category: [`lint/style/noUnusedTemplateLiteral`](/reference/diagnostics#diagnostic-category) - This rule isn't recommended, so you need to enable it. - This rule has a [**safe**](/linter/#safe-fixes) fix. - The default severity of this rule is [**warning**](/reference/diagnostics#warning). ## How to configure ```json title="biome.json" { "linter": { "rules": { "style": { "noUnusedTemplateLiteral": "error" } } } }## Description
Disallow template literals if interpolation and special-character handling are not needed
## Examples
### Invalid
```js
const foo = `bar`
const foo = `bar `
const foo = `bar
has newline`;
const foo = `"bar"`
const foo = `'bar'`