share-button-links
Share buttons links for websites, blogs and more.
2,540
15
| Install | |
|---|---|
npm install share-button-links |
|
| Latest Version: | 2.3.9 |
| Vue: | 3 |
| License: | MIT |
| Last Updated: | Mar 15, 2026 |
| Links: | GitHub · npm |
Maintainer: blaster203
Share Button Links
Vue 3 share buttons for websites, blogs, docs and landing pages.
Installation
npm install share-button-links
or
yarn add share-button-links
Exports
The package root exports the library styles and all public components.
Buttons
import {
ButtonCopy,
ButtonEmail,
ButtonFacebook,
ButtonLinkedIn,
ButtonPinterest,
ButtonPocket,
ButtonReddit,
ButtonTelegram,
ButtonTumblr,
ButtonTwitter,
ButtonWhatsapp
} from "share-button-links";
Icon Buttons
import {
CopyIcon,
EmailIcon,
FacebookIcon,
LinkedInIcon,
PinterestIcon,
PocketIcon,
RedditIcon,
TelegramIcon,
TumblrIcon,
TwitterIcon,
WhatsappIcon
} from "share-button-links";
Button Group
import { ButtonGroupIcons } from "share-button-links";
You can also import submodules directly if you prefer:
import { ButtonFacebook } from "share-button-links/components/buttons";
import { FacebookIcon } from "share-button-links/components/icons";
import ButtonGroupIcons from "share-button-links/components/button-group";
Styles
The package ships with compiled CSS and the original SCSS entry.
@import "share-button-links/dist/share-button-links.css";
@use "share-button-links/dist/share-button-links.scss";
Basic Usage
<script setup lang="ts">
import { ButtonFacebook, TwitterIcon, ButtonGroupIcons } from "share-button-links";
</script>
<template>
<ButtonFacebook
url="https://example.com/article"
title="A shareable article"
text="Facebook"
has-icon
is-rounded
/>
<TwitterIcon
url="https://example.com/article"
title="A shareable article"
is-circled
/>
<ButtonGroupIcons
url="https://example.com/article"
title="A shareable article"
message="Take a look at this"
description="Reusable Vue share buttons"
media-url="https://example.com/cover.png"
content="Extra text for Tumblr or email"
subject="Check this out"
is-rounded
facebook-icon
twitter-icon
telegram-icon
whatsapp-icon
copy-icon
/>
</template>
Shared Props
Most button components support:
isRounded?: booleanisCircled?: booleanisBordered?: boolean
Text buttons also support:
hasIcon?: boolean
Icon buttons also support:
isAllWhite?: booleanisWhited?: boolean
Copy Button Props
ButtonCopy and CopyIcon support copying a URL and show live feedback after success.
Common props:
url: stringtext?: stringforButtonCopyhasIcon?: booleanforButtonCopy
Network-Specific Props
Some components require extra data depending on the destination:
titlefor Facebook, Twitter, Reddit, Pocket and Tumblr.messagefor WhatsApp and Telegram.descriptionandmediaUrlfor Pinterest.to,subjectandcontentfor Email.contentfor Tumblr.
Accessibility Contract
- Icon-only components expose an
aria-labeland keep decorative SVGs hidden from screen readers. - Copy components expose success feedback through
aria-live="polite". - Interactive controls keep native semantics with
<a>or<button type="button">. - Focus styling is visible through
:focus-visible.
Local Development
npm run dev
Useful commands:
npm run buildbuilds the library bundles.npm run previewserves the local production build.npm run test:unitruns the unit tests.npm run lintruns ESLint with auto-fix.npm run size:reportprints the bundle size report.
Notes
ButtonLine.vueis legacy and is not part of the public API exports.- Most SVG icons come from Bootstrap Icons and Tabler Icons.
Documentation
Docs site: share-button-links.netlify.app
Related Packages
Version History
| Version | Released | Vue | License |
|---|---|---|---|
| 2.3.9 | ^3.5.0 | MIT | |
| 2.3.8 | ^3.5.0 | MIT | |
| 2.3.7 | ^3.3.4 | MIT | |
| 2.3.6 | ^3.3.4 | MIT | |
| 2.3.5 | ^3.2.45 | MIT | |
| 2.3.4 | ^3.2.45 | MIT | |
| 2.3.3 | ^3.2.45 | MIT | |
| 2.3.2 | MIT | ||
| 2.3.1 | MIT | ||
| 2.3.0 | MIT | ||
| 2.2.4 | MIT | ||
| 2.2.3 | MIT | ||
| 2.2.2 | MIT | ||
| 2.2.1 | MIT | ||
| 2.2.0 | MIT | ||
| 2.1.0 | MIT | ||
| 2.0.2 | MIT | ||
| 2.0.1 | MIT | ||
| 2.0.0 | MIT | ||
| 1.1.0 | MIT | ||
| 1.0.0 | MIT |
Pre-releases (5)
| Version | Released | License |
|---|---|---|
| 1.1.0-alpha | MIT | |
| 1.0.3-alpha | MIT | |
| 1.0.2-alpha | MIT | |
| 1.0.1-alpha | MIT | |
| 1.0.0-alpha | MIT |