> ## Documentation Index
> Fetch the complete documentation index at: https://vuemail.dev/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Button

> A link that is styled to look like a button.

> [!NOTE]
>
> Semantics: Quite often in the email world we talk about buttons, when actually
> we mean links. Behind the scenes this is a `<a>` tag, that is styled like a `<button>` tag.

## Install

Install component from your command line.

```sh npm theme={null}
npm install @vuemaildev/vuemail -E
```

```sh yarn theme={null}
yarn add @vuemaildev/vuemail -E
```

```sh pnpm theme={null}
pnpm add @vuemaildev/vuemail -E
```

## Getting started

Add the component to your email template. Include styles where needed.

```vue theme={null}
<script setup lang="ts">
import { Button } from '@vuemaildev/vuemail';
</script>

<template>
  <Button
    href="https://example.com"
    :style="{ color: '#42b883', padding: '10px 20px' }"
  >Click me</Button>
</template>
```

> [!NOTE]
>
> In Vue templates, text written over several lines inside a component keeps a single space at
> each end, where JSX trims it. Write short texts like button labels on one line when exact spacing
> matters, as above.

## Props

**href** `string` *required*

Link to be triggered when the button is clicked

**target** `string` (default: \_blank)

Specify the target attribute for the button link

## Support

All components were tested using the most popular email clients.

![Gmail](https://vuemail.dev/static/icons/gmail.svg)

Gmail

![Apple Mail](https://vuemail.dev/static/icons/apple-mail.svg)

Apple Mail

![Outlook](https://vuemail.dev/static/icons/outlook.svg)

Outlook

![Yahoo! Mail](https://vuemail.dev/static/icons/yahoo-mail.svg)

Yahoo! Mail

![HEY](https://vuemail.dev/static/icons/hey.svg)

HEY

![Superhuman](https://vuemail.dev/static/icons/superhuman.svg)

Superhuman


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.