0.0.4 • Published 8 months ago

phantom-iframe-connector v0.0.4

Weekly downloads
-
License
MIT
Repository
github
Last release
8 months ago

Phantom Iframe Connector

Description

This repository offers a streamlined solution for DApps operating within an iframe to establish a connection with the Phantom Wallet browser extension.

Usage

Installing

Install package as a dependency of your project: yarn add phantom-iframe-connector or npm install phantom-iframe-connector

Usage

Example using React.js:

import { enablePhantomWalletExtension } from "phantom-iframe-connector";
const Component = () => {
  useEffect(() => {
    // Run this once client side is ready
    enablePhantomWalletExtension({ iframeOrigin: 'https://solana.frenslink.dev' });
  }, []);
  return (
    // The D-APP that runs inside iframe
    <iframe src="https://solana.frenslink.dev/multilinks?tokenAddress=Gh9ZwEmdLJ8DscKNTkTqPbNwLNNBjuSzaG9Vp2KGtKJr" />
  );
};
0.0.4

8 months ago

0.0.3

8 months ago

0.0.2

8 months ago

0.0.1

8 months ago