@screaming/share
Introduction
@screaming/share provides a single Vue 3 component, <ShareLink />
, which easily facilitates creating social share links.
Installation
TIP
@screaming/share comes pre-installed in all @screaming/froggo projects.
Install with your favourite package manager:
sh
# yarn
yarn add @screaming/share
# pnpm
pnpm add @screaming/share
# npm
npm install @screaming/share
1
2
3
4
5
6
7
8
2
3
4
5
6
7
8
Import as required:
vue
<!-- script setup (recommended) -->
<script setup lang="ts">
import { ShareLink } from '@screaming/share'
</script>
<template>
<ShareLink to="...">...</ShareLink>
</template>
1
2
3
4
5
6
7
8
2
3
4
5
6
7
8
vue
<!-- using defineComponent (old school vue) -->
<script lang="ts">
import { defineComponent } from 'vue'
import { ShareLink } from '@screaming/share'
export default defineComponent({
components: { ShareLink }
})
</script>
<template>
<ShareLink to="...">...</ShareLink>
</template>
1
2
3
4
5
6
7
8
9
10
11
12
13
2
3
4
5
6
7
8
9
10
11
12
13