Move swap component into separate module

This commit is contained in:
armaniferrante 2021-05-15 02:28:27 -07:00
parent 7b0cd96c4a
commit 44917ee3df
No known key found for this signature in database
GPG Key ID: 58BEF301E91F7828
13 changed files with 7 additions and 2 deletions

View File

@ -12,7 +12,7 @@ import {
TransactionSignature, TransactionSignature,
} from "@solana/web3.js"; } from "@solana/web3.js";
import { TokenListProvider } from "@solana/spl-token-registry"; import { TokenListProvider } from "@solana/spl-token-registry";
import Swap from "./components/Swap"; import Swap from "./swap";
import "./App.css"; import "./App.css";
// App illustrating the use of the Swap component. // App illustrating the use of the Swap component.

5
src/swap/index.ts Normal file
View File

@ -0,0 +1,5 @@
// The swap module exports a single `Swap` component that can be embedded into
// applications.
import Swap from "./components/Swap";
export default Swap;

View File

@ -1,5 +1,5 @@
// TODO: replace this whole file with something more modern. This is all copied // TODO: replace this whole file with something more modern. This is all copied
// from sollet.. // from sollet.
import * as BufferLayout from "buffer-layout"; import * as BufferLayout from "buffer-layout";
import { BN } from "@project-serum/anchor"; import { BN } from "@project-serum/anchor";