discountcoupon-library

1.0.26 • Public • Published

Discount Coupon Library

The Discount Coupon Library is a package that provides a reusable component to display discount coupons in React applications.

Installation

To install the Discount Coupon Library, use your preferred package manager:

npm install discountcoupon-library

or

yarn add discountcoupon-library

Usage

Import the DiscountCoupon component into your React application as shown below: import { DiscountCoupon } from 'discountcoupon-library';

Props:

The DiscountCoupon component takes the following props:

couponData: An object containing the coupon information with the following properties:

code: The coupon code (string) discount: The discount amount (string) description: Description of the coupon (string) image: Path to the coupon image (string) onShare: Function to handle the share button click event.

onLearnMore: Function to handle the 'Know More' link click event.

Styling

The library includes predefined CSS classes to style the coupon component. You can also customize these styles according to your preferences.

Readme

Keywords

none

Package Sidebar

Install

npm i discountcoupon-library

Weekly Downloads

1

Version

1.0.26

License

ISC

Unpacked Size

18.1 kB

Total Files

17

Last publish

Collaborators

  • archana0405