1.1.3 • Published 2 years ago

awesome-pay v1.1.3

Weekly downloads
-
License
-
Repository
github
Last release
2 years ago

Awesome Pay

This is a virtual payment module made from react.

🌈 Install

npm install awesome-pay

🌈 Usage

Setting

public/index.html

<body>
  ...
  <div id="modal"></div>
  ...
</body>

Use

import { PayModal } from 'awesome-pay';

export default function Component({ totalPrice }) {
  const [showModal, setShowModal] = useState(false);

  const toggleShowModal = () => {
    setShowModal(prevState => !prevState);
  };

  const paymentFunc = () => {
    toggleShowModal();
    // Do Something What You Want
  };

  return (
    <div>
      ...
      <PayModal
        showModal={showModal}
        toggleShowModal={toggleShowModal}
        companyName={companyName}
        totalPrice={totalPrice}
        paymentFunc={paymentFunc}
      />
      ...
    </div>
  );
}

🌈 Author

npm.io
LeeAhHyun
1.1.3

2 years ago

1.1.2

2 years ago

1.1.1

2 years ago

1.1.0

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago

0.0.8

2 years ago

0.0.7

2 years ago

0.0.6

2 years ago

0.0.5

2 years ago

0.0.4

2 years ago

0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago