fdk-share
You are reading an outdated document
Get the latest developer guides on Fynd Partners Help
Share Action Component
- Tag:
- fdk-share
- Description:
- This displays the shareable QR code and the various social links to share the cart, product or listing with any other person.
Props
Key | Type | Description |
---|---|---|
share_link | string | store link to be shared |
cartShareLink | function | handler to generate share link on cart page, this returns a link |
getShareLink | function | handler to generate share link on product description or listing pages, this returns a link |
generateQRCode | function | handler to generate shareable QR code of page URL, this returns a svg image |
- cartShareLink
- Params:
- uid => Bag ID to be passed
- eid => Employee ID to be passed
- Example:
- cartShareLink(uid, eid)
- Params:
- getShareLink
- Params:
- url => url of the page of which shareable link will be generated (url of Product description and listing pages)
- Example:
- getShareLink(url)
- Params:
- generateQRCode
- Params:
- url => URL to be passed to generate QR code
- Example:
- generateQRCode(url)
- Params:
Example
in the following manner you can use this fdk-share action component
<fdk-share>
<template slot-scope="share">
<div @click="getShareLink(share)">
<fdk-inline-svg :src="'share'"></fdk-inline-svg>
<transition name="fade">
<share
:title="`Spread the shopping delight! Scan QR`"
:share_link="share_link"
/>
</transition>
</div>
</template>
</fdk-share>