> 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-useless-continue

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

| Preset                              | Configured Value |
| ----------------------------------- | ---------------- |
| ✅ unicornPlugin.configs.recommended | `"error"`        |


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

export default defineConfig([
  unicornPlugin.configs.recommended,
  {
    rules: {
      'unicorn/no-useless-continue': 'error',
    },
  },
]);
```

Disallow an unlabeled `continue` statement when the current loop iteration would end at the same point without it. The rule fixes the statement automatically and preserves adjacent comments.

```javascript
// Incorrect
for (const item of items) {
  process(item);
  continue;
}

// Correct
for (const item of items) {
  process(item);
}
```

Labeled `continue` statements, bare loop bodies, and statements inside a `switch` or `try` are left alone.

## Options

This rule has no options. It is enabled at `error` severity in `unicornPlugin.configs.recommended`.

## Differences from upstream

When removing a standalone statement from a CRLF file, the fix removes the whole preceding CRLF sequence. Unicorn v76.0.0 removes only the newline byte in this case, leaving an extra carriage return.

## Original Documentation

- [eslint-plugin-unicorn: no-useless-continue](https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v76.0.0/docs/rules/no-useless-continue.md)
- [Source code](https://github.com/sindresorhus/eslint-plugin-unicorn/blob/v76.0.0/rules/no-useless-continue.js)
