A one line React staking widget for Sui that utilizes Aftermath's liquid staking protocol to mint afSUI in exchange for SUI.
npm i aftermath-staking-widget
import { AftermathStakingWidget } from "aftermath-staking-widget";
function App() {
return <AftermathStakingWidget />;
}
export default App;
interface AftermathStakingWidgetProps {
// display
theme?: "dark" | "light";
transparentBackground?: boolean;
border?: boolean;
rounded?: boolean;
width?: string | number;
height?: string | number;
// general
referrer?: SuiAddress;
network?: "MAINNET" | "TESTNET" | "DEVNET" | "LOCAL" | string;
// staking
validator?: SuiAddress;
fixValidator?: boolean;
onlyValidators?: SuiAddress[];
}
Find the complete documentation for using our Typescript SDK in our GitBook.