August 28th 2024
New
Improved
We’ve enhanced our API to take the regionalization of your purchases to the next level. With our latest update, it’s now possible to reduce the number of required fields for completing a purchase in each country. This update allows you to display only the mandatory fields and hide the optional ones, reducing friction and speeding up the checkout process.
💡 Additionally, with custom Javascript, you have the flexibility to make specific fields mandatory to meet your business needs.
Display only required fields: You can now easily hide all optional fields on your checkout forms by adding a single line of custom CSS.
.optional-field {
display: none;
}
Target specific fields: If you prefer to hide individual fields instead of all optional ones, you can now target specific fields using their unique element IDs.
#phone-field {
display: none;
}
Set Fields as Required: For businesses that need to enforce the collection of specific information, we’ve added the ability to mark any input field as required using custom JavaScript.
const phoneNumberInput = document.getElementsByName('phoneNumber')[0];
phoneNumberInput.required = true;
Check out all the details of this new feature in our docs.