React widgets for AlignMint protocol - mint and unmint operations
npm install @ankrlabs/widgetsReact widgets for AlignMint Full-Reserve protocol - mint and unmint operations.
``bash`
npm install @ankrlabs/widgets
`tsx
import { MintUnmintWidget } from '@ankrlabs/widgets';
function App() {
return (
wagmiConfig={wagmiConfig}
/>
);
}
`
`tsx
import { MintUnmintWidget } from '@ankrlabs/widgets';
import { QueryClient, QueryClientProvider } from '@tanstack/react-query';
import { WagmiProvider } from '@privy-io/wagmi';
import { PrivyProvider } from '@privy-io/react-auth';
const queryClient = new QueryClient();
function App() {
return (
wagmiConfig={wagmiConfig}
/>
);
}
`
| Prop | Type | Required | Description |
|------|------|----------|-------------|
| appChainId | number | ✅ | The chain ID for the application |wagmiConfig
| | Config | ✅ | Wagmi configuration object |
- Node.js 18+
- Yarn 4+
`bashInstall dependencies
yarn install
$3
-
yarn build - Build the library for production
- yarn dev - Start development server (uses source files)
- yarn dev:built - Start development server with built files from dist/
- yarn lint - Run ESLint
- yarn lint:fix - Fix ESLint errors
- yarn typecheck - Run TypeScript type checking$3
To test the production build locally in examples:
`bash
1. Build the library first
yarn build2. Run dev server with built files
yarn dev:built
`This allows you to test the actual production build (
dist/`) before publishing to npm.