---
url: https://scruple.dev/rules/comments/no-misleading-comments.md
description: Disallow claims contradicted by visible code.
---

# comments/no-misleading-comments

Disallow claims contradicted by visible code.

## What it checks

Concrete comment claims should remain consistent with the current behavior visible next to them.

## Rule metadata

* Package: `@scruple/comments`
* Category: Comment correctness
* Tags: accuracy, maintenance, behavior
* Default threshold: `0.85`
* Minimum confidence: `0.7`

## Examples

### Reported

```ts
// Cache for one minute.
const ttlMs = 3_600_000;
```

### Accepted

```ts
// Cache for one hour.
const ttlMs = 3_600_000;
```
