> For AI agents: the complete documentation index is available at https://rslint.rs/llms.txt, the full documentation bundle is available at https://rslint.rs/llms-full.txt.

# no-multi-str

[Added in v0.4.2](https://github.com/web-infra-dev/rslint/releases/tag/v0.4.2)
## Configuration


```ts title=rslint.config.ts
import { defineConfig, js } from '@rslint/core';

export default defineConfig([
  js.configs.recommended,
  {
    rules: {
      'no-multi-str': 'error',
    },
  },
]);
```

## Rule Details

Disallows multiline strings created using a trailing backslash before a line break. This syntax was historically an undocumented feature of JavaScript and should be avoided.

Examples of **incorrect** code for this rule:

```javascript
var x =
  'Line 1 \
         Line 2';
```

Examples of **correct** code for this rule:

```javascript
var x = 'Line 1 ' + 'Line 2';

var x = `Line 1
         Line 2`;
```

## Original Documentation

- [ESLint: no-multi-str](https://eslint.org/docs/latest/rules/no-multi-str)
- [Source code](https://github.com/eslint/eslint/blob/v10.8.1/lib/rules/no-multi-str.js)
