This package has been deprecated

Author message:

🚨🚨🚨🚨 WARNING: This project has been renamed to 'plugin' and no longer will be maintained here. Install using @socket.tech/plugin instead.

@socket.tech/widget
TypeScript icon, indicating that this package has built-in type declarations

0.2.4Β β€’Β PublicΒ β€’Β Published

Socket Widget

Seamless bridging experience into a single fully customizable React Component

npm version Downloads Github Stars License

Socket’s Widget is a React component that can be easily imported in any React (JS/TS) project. The widget supports most features from Bungee.exchange. It brings the seamless bridging UX from Bungee to any DApp!

Themes

The widget requires provider from user’s connected wallet & Socket’s API_KEY as props to initialise. Optional props can be passed to customize the widget’s color scheme, pre-select the chains/tokens & also customize token lists.

The full documentation for the widget can be found here

Installation

The widget can be installed via NPM or Yarn.

NPM :

npm install @socket.tech/widget

Yarn :

yarn add @socket.tech/widget

Note : The widget requires react (>=17.0.1) and react-dom (>=17.0.1) as peerDepencies.

Initialization

Copy the snippet below to get started! Pass the API_KEY from a .env file and Provider from user’s connected wallet.

import { Bridge } from "@socket.tech/widget";
import { Provider } from "./providerComponent"

function SocketBridge() {
    return (    
    	<Bridge
	  provider={Provider}
	  API_KEY={process.env.SOCKET_API_KEY} 
	/>
    )
}

export default SocketBridge;

That’s it! You’ve successfully plugged your DApp into Socket! πŸ”ŒΒ  For further customising the widget, check the widget docs.

Documentation

Example App

Work In Progress πŸ› 

More themes... 😎

More Themes

Package Sidebar

Install

npm i @socket.tech/widget

Weekly Downloads

11

Version

0.2.4

License

MIT

Unpacked Size

428 kB

Total Files

84

Last publish

Collaborators

  • vaibhavchellani
  • arthcp
  • salilnaik
  • themaskedman981
  • ameesha12
  • shreykeny
  • vamsireddy9672
  • khaledkaddal
  • sebastian-socket