# require-prop-comment

Rule `vue/require-prop-comment`. Require props to have a comment

- Source: vue
- Technologies: Vue
- Kind: style
- Needs type information: no
- Autofix: no
- Reach: 0 weekly downloads of presets that enable it
- Trend: 0% last quarter
- Rank: #2084 by reach

## Linters

| Linter | Rule name | Recommended | Autofix | Details | Docs |
| --- | --- | --- | --- | --- | --- |
| ESLint | `vue/require-prop-comment` | no | no | package `eslint-plugin-vue` | [docs](https://eslint.vuejs.org/rules/require-prop-comment.html) |

## Code examples

### Incorrect: the rule reports this

```vue
    // line comment
    b: Number,

    /* block comment */
    c: Number,

    d: Number,
  }
})
</script>
```

```vue
const badProps = defineProps({
  /** JSDoc comment */
  b: Number,

  // line comment
  c: Number,

  d: Number,
})
</script>
```

```vue
const badProps = defineProps({
  /** JSDoc comment */
  b: Number,

  /* block comment */
  c: Number,

  d: Number,
})
</script>
```

### Correct: the rule accepts this

```vue
/** JSDoc comment */
a: Number,
```

```vue
const goodProps = defineProps({
  /* block comment */
  a: Number,
})
```

```vue
const goodProps = defineProps({
  // line comment
  a: Number,
})
```

Examples from the ESLint documentation.

## Enable it

### ESLint: `eslint.config.js`

```js
import vue from "eslint-plugin-vue";

export default [
  {
    plugins: { vue },
    rules: {
      "vue/require-prop-comment": "error",
    },
  },
];
```

## Related rules

- [vue/require-name-property](https://lintradar.dev/rules/vue/require-name-property.md): Require a name property in Vue components
- [vue/restricted-component-names](https://lintradar.dev/rules/vue/restricted-component-names.md): Enforce using only specific component names
- [vue/require-expose](https://lintradar.dev/rules/vue/require-expose.md): Require declare public properties using `expose`
- [vue/script-indent](https://lintradar.dev/rules/vue/script-indent.md): Enforce consistent indentation in `<script>`
- [vue/padding-lines-in-component-definition](https://lintradar.dev/rules/vue/padding-lines-in-component-definition.md): Require or disallow padding lines in component definition
- [vue/sort-keys](https://lintradar.dev/rules/vue/sort-keys.md): Enforce sort-keys in a manner that is compatible with order-in-components

---

Web page: https://lintradar.dev/rules/vue/require-prop-comment. Data from npm and the linters' documentation, collected Dec 4, 2026. Site guide for agents: https://lintradar.dev/llms.txt
