How to add new custom fields in checkout using checkout-sdk-js of bigcommerce?

309 Views Asked by At

How to add new custom fields in checkout using checkout-sdk-js of bigcommerce?

SDK:       https://github.com/bigcommerce/checkout-sdk-js

Example: https://github.com/bigcommerce/checkout-sdk-js

After fields add data of custom fields will be stored? How?

P.S. - I did a lot of search about it, but didn't get it that's why I've created this questions.

1

There are 1 best solutions below

0
On

About storing the custom fields' data -- this depends on which framework you build your checkout with. If you decide to go with React, for example, you will store this 'new data' in the react state. To continue this example with React in mind, you can add new custom fields to the .jsx file depending on where you are needing these form fields to be located. However, the checkout SDK is written in vanilla JS, meaning it is completely framework-agnostic. So you can build your checkout in React, Angular, Vue, or even just plain HTML and JavaScript–whichever frontend framework you prefer to build in.