3.0.8 • Published 5 months ago

boundless-checkout-react-cp v3.0.8

Weekly downloads
-
License
MIT
Repository
github
Last release
5 months ago

Boundless Checkout React Component

Checkout React Component for Boundless Commerce.

About Boundless Commerce

API’s First Headless E-commerce CMS: We Provide An Admin-Side For Store Management, Powerful API, And Ready-To-Use Checkout Area.

Self-Hosted solution

There is an option for Running Boundless-Commerce on your own server. Read more at Open-Source Headless eCommerce Platform

Installation

Besides the checkout component the API client should be installed:

yarn add boundless-api-client boundless-checkout-react

Or via NPM:

npm install boundless-api-client boundless-checkout-react --save

Getting Started

  1. Create client:
import {BoundlessClient} from 'boundless-api-client';
const apiClient = new BoundlessClient('<YOUR PERMANENT TOKEN>');
apiClient.setInstanceId('<YOUR INSTANCE ID>');
  1. Add component to the checkout page:
import {startCheckout, StarterWrapper} from 'boundless-checkout-react';

const starter = startCheckout(document.querySelector('.some-el'), {
	api: apiClient,
	onHide: () => console.log('on hide'),
	onThankYouPage: (data) =>  console.log('on thank you page', data),
	basename: '/shop/checkout',
	cartId: 'uid',
	logoSrc: 'https://domain/logo.png',
	logoText: 'My Logo'
});

Props api, onHide, onThankYouPage - are required, others are optional.

basename - Start url for the checkout. If checkout located at /checkout, then basename: '/checkout'.

  1. Need more example? Look at: Checkout page at Next.js

Development process

  1. Copy & adjust .env.example => .env
  2. yarn dev - starts dev server at http://localhost:8080
  3. Real component usage can be tested locally via yarn link or manually creation symbolic link in node_modules.

NextJS eCommerce templates - Free. Ready to use. Just clone & deploy!

3.0.4

5 months ago

3.0.3

5 months ago

3.0.2

5 months ago

3.0.8

5 months ago

3.0.7

5 months ago

3.0.6

5 months ago

3.0.5

5 months ago

3.0.1

5 months ago

3.0.0

6 months ago

2.0.1

6 months ago

2.0.0

6 months ago

1.0.29

8 months ago

1.0.28

9 months ago

1.0.27

9 months ago

1.0.26

9 months ago

1.0.25

9 months ago

1.0.22

9 months ago

1.0.21

9 months ago

1.0.20

9 months ago

1.0.24

9 months ago

1.0.23

9 months ago

1.0.19

9 months ago

1.0.18

9 months ago

1.0.17

9 months ago

1.0.16

10 months ago

1.0.15

10 months ago

1.0.14

10 months ago

1.0.13

10 months ago

1.0.12

10 months ago

1.0.11

10 months ago

1.0.10

10 months ago

1.0.9

10 months ago

1.0.8

10 months ago

1.0.7

10 months ago

1.0.6

10 months ago

1.0.5

10 months ago

1.0.4

10 months ago

1.0.3

10 months ago

1.0.2

10 months ago

1.0.1

10 months ago

1.0.0

10 months ago