# @felixwochnick/vue-docgen-vetur

> Generate vetur component data for your vue component library

Latest version **0.1.1** (published 2022-10-04) · MIT license · 0 weekly downloads

## Install

```sh
npm install @felixwochnick/vue-docgen-vetur
pnpm add @felixwochnick/vue-docgen-vetur
yarn add @felixwochnick/vue-docgen-vetur
bun add @felixwochnick/vue-docgen-vetur
```

Provides the command `vue-docgen-vetur`.

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 0.1.1 |
| Published | 2022-10-04 |
| First published | 2022-10-04 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 6 |
| Unpacked size | 12.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Ruben Gees |
| Maintainers | felixwochnick |
| Keywords | vue, docgen, vetur, components, generator, tooling |

## Links

- npm: https://www.npmjs.com/package/@felixwochnick/vue-docgen-vetur
- Repository: https://github.com/SmartsquareGmbH/vue-docgen-vetur
- Homepage: https://github.com/SmartsquareGmbH/vue-docgen-vetur#readme
- Issues: https://github.com/SmartsquareGmbH/vue-docgen-vetur/issues
- npm.io page: https://npm.io/package/@felixwochnick/vue-docgen-vetur

## Dependencies (6)

- [mkdirp](https://npm.io/package/mkdirp.md) ^1.0.4
- [pkginfo](https://npm.io/package/pkginfo.md) ^0.4.1
- [commander](https://npm.io/package/commander.md) ^8.3.0
- [fast-glob](https://npm.io/package/fast-glob.md) ^3.2.7
- [param-case](https://npm.io/package/param-case.md) ^3.0.4
- [vue-docgen-api](https://npm.io/package/vue-docgen-api.md) ^4.41.2

## Recent versions

- 0.1.1 (latest) — 2022-10-04
- 0.1.0 — 2022-10-04

## README

# vue-docgen-vetur ![npm](https://img.shields.io/npm/v/vue-docgen-vetur) ![GitHub Workflow Status](https://img.shields.io/github/workflow/status/SmartsquareGmbH/vue-docgen-vetur/CI)

Generate vetur component data for your vue component library.

### Installation

`npm i -D vue-docgen-vetur`

### Usage

Run the generator from your project: `vue-docgen-vetur`.

The resulting files are generated into the current directory per default. The input and output directory can be
customized by passing them as arguments:

`vue-docgen-vetur -o dist/json src/components/**/*.vue`

Generate vetur docs with prefix:

`vue-docgen-vetur -o dist/json src/components/**/*.vue -p D`

The input supports the glob syntax. See [`fast-glob`](https://www.npmjs.com/package/fast-glob) for details.

For convenience, this call can be added to the `scripts` in the `package.json`:

```json
{
  "scripts": {
    "build:meta": "vue-docgen-vetur -o dist/json"
  }
}
```

For Vetur to detect the generated files, add another section to the `package.json`:

```json
{
  "vetur": {
    "tags": "dist/json/tags.json",
    "attributes": "dist/json/attributes.json"
  }
}
```

### Example

Relevant data is parsed from the documentation of your components. Given this component:

```vue
<template>
  <div>{{ text }}</div>
</template>

<script>
/**
 * My component
 */
export default {
  props: {
    /**
     * The text to display
     */
    text: {
      type: String,
      default: "Hello",
    },
  },
}
</script>
```

Vetur shows autocompletion:

| Component                                                                                                                     | Prop                                                                                                                     |
| ----------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------ |
| ![component-completion](https://user-images.githubusercontent.com/8021265/142169577-7d8b2c8c-01e7-4bec-a32e-f02a6e729ace.png) | ![prop-completion](https://user-images.githubusercontent.com/8021265/142169590-cca078b7-af11-4596-8802-2a0e8c54e621.png) |

---
_Source: https://npm.io/package/@felixwochnick/vue-docgen-vetur · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
