add-to-cart-button
TypeScript icon, indicating that this package has built-in type declarations

1.0.16 • Public • Published

🚀 Simple add to cart button for ecommerce apps



Installation

npm install add-to-cart-button

Usage

import { AddToCartButton } from 'add-to-cart-button'

....

    const [isAdded, setIsAdded] = useState(false);
....

    const handleAdd = () => {
        setIsAdded(v => !v)
    }
....

    <AddToCartButton handleAdd={handleAdd} isAdded={isAdded} />

...

Readme

Keywords

none

Package Sidebar

Install

npm i add-to-cart-button

Weekly Downloads

2

Version

1.0.16

License

ISC

Unpacked Size

14.7 kB

Total Files

12

Last publish

Collaborators

  • akshaypatil0