Skip to content

google-wallet/save-to-google-pay-button

Repository files navigation

The Save to Google Pay button

The Save to Google Pay button makes it easy embed the Save to Google Pay functionality into your websites.

Save to Google Pay

This repository takes the Save to Google Pay button experience and makes the integration process easier for those building websites with frameworks like React, Angular, Vue (and many others), or even those who don't use a framework.

Web component

npm version

The Save to Google Pay web component button makes it easy to integrate the Save to Google Pay button into your website using standards based custom elements. Web components can be used directly in a standard HTML web application as is, and is also compatible with many popular web frameworks.

npm install @google-pay/save-button-element

Find out more about the Save to Google Pay web component button.

React

npm version

Web components are more difficult to consume in a React application due to the extra work involved in binding to web component properties with React.

A separate Save to Google Pay React button as been created to make it just as easy to integrate the Save to Google Pay button into your React website.

npm install @google-pay/save-button-react

Find out more about the Save to Google Pay React button.

Angular

npm version

An Angular version of the Save to Google Pay button as been created to make it just as easier to integrate the Save to Google Pay button into your Angular website. The advantage of using the Angular version of the Google Pay button over the web component is that it eliminates the need to register CUSTOM_ELEMENTS_SCHEMA.

npm install @google-pay/save-button-angular

Find out more about the Save to Google Pay Angular button.

Other frameworks

The intention is for the web component to support other web frameworks. Support for additional framework specific libraries will be considered based on demand.

Have any questions?

Ask it on the discussions section of the Google Pay button project.