March 31, 2023
Polygon News

Polygon x Bridge Widget: Easy dApp Access & Asset Transfer

Developers rejoice! Accessing Polygon from within your dApp gets easy with Bridge Widget

Polygon x Bridge Widget: Easy & Seamless dApps

Polygon and Bridge Widget want to make it easier for you to transfer assets and initiate seamless dApp interactions. Bridge Widget is a simplified gateway allowing easy access to Polygon via an in-app bridge. The tool would facilitate access to Polygon without shifting to another page via accessing a “bite-sized, simple, and easy-to-use plug tool,” or the Bridge Widget.

Bridge Widget: Usage, Design, & Implementation

The Bridge Widget is a high-utility tool allowing access to various Polygon Bridge features easily from within your application. Polygon’s Widget dashboard acts as a workshop for you to customize. In it, you can select the default token, supported tokens, configure the layout and various alternatives to personalize the overall UX. Simply install the widget library and add to your dApp the code snippet to enhance the UX by facilitating a seamless transfer of assets among Ethereum and Polygon. 

Installing Bridge Widget

After widget design and implementation processes are done, all that remains is efficient integration. To integrate, simply click on the ‘Get Code Snippet’ button. Then copy the Code snippet to paste it in your application code.

An illustration of how the code snippet looks like for widget integration:

import { Widget } from “@maticnetwork/wallet-widget”;

const widget = new Widget({ target: ‘#btnOpenWidget’, appName: “test”, position:”bottom-right”, network:”testnet”, height: 630, width:500 });

// create widget widget.create();

To access configuration assistance, kindly visit: widget config doc

An all-in-one Polygon experience awaits to enlighten you with its robust seamlessness. You will also be a cheerful recipient of the same Polygon Wallet Support as these transactions are treated as equal to the Polygon bridge.

Access this guiding document as a widget development reference. An illustration is also available for your viewing. You might want to check the implementation video, as well:

Introducing Widget – Polygon bridge on your Dapp