---
title: "format/comments/single-line-spacing"
pagination: false
---

{/* Generated by scripts/gen-rule-docs.py. Edit mapping.toml, not this file. */}

<RuleId id="format/comments/single-line-spacing" />

In the [`format-laravel`](/docs/rules/presets/format-laravel) preset. Safe fix.

## What it does

Single-line comments must have proper spacing.

## Configuration

```toml title="pun.toml"
[format.rules]
"comments/single-line-spacing" = true
```

To skip it in some files, add a [`@pun-ignore-file`](/docs/configuration/ignore-comments) comment.

## Replaces

- [`single_line_comment_spacing`](https://cs.symfony.com/doc/rules/comment/single_line_comment_spacing.html) (php-cs-fixer)

[More format/comments rules](/docs/rules/format/comments) · [Edit this page](https://github.com/shipfastlabs/pun/edit/main/crates/pun-config/rules/mapping.toml)
