0.9.1 • Published 20 days ago
@cowprotocol/widget-react v0.9.1
CoW Swap React widget
React component that creates a CoW Swap widget. It is based on https://npmjs.com/package/@cowprotocol/widget-lib
Use it
Install dependency
yarn add @cowprotocol/widget-react
npm install @cowprotocol/widget-react
Import component and some convenient types
import { CowSwapWidget, CowSwapWidgetParams } from '@cowprotocol/widget-react'
Prepare the config for the widget:
const cowSwapWidgetParams: CowSwapWidgetParams = {
appCode: 'NAME-OF-YOU-APP', // Add here the name of your app. e.g. "Pig Swap"
width: '600px',
height: '700px',
tradeType: 'swap',
}
Render the component:
<CowSwapWidget params={cowSwapWidgetParams} />
Developers
# Test
nx test widget-react
# Build the library
nx build widget-react
# Publish to NPM
nx publish widget-react --ver x.y.z --tag latest
0.9.1
20 days ago
0.9.0
21 days ago
0.8.2
29 days ago
0.8.1
1 month ago
0.8.0
1 month ago
0.7.1
1 month ago
0.7.0
1 month ago
0.7.0-RC.0
1 month ago
0.6.0
1 month ago
0.5.0
2 months ago
0.5.0-RC.4
3 months ago
0.5.0-RC.1
3 months ago
0.5.0-RC.2
3 months ago
0.5.0-RC.3
3 months ago
0.5.0-RC.0
3 months ago
0.4.0
3 months ago
0.3.0
4 months ago
0.1.0
7 months ago
0.2.1
6 months ago
0.2.0
6 months ago
0.1.1
7 months ago
0.2.3
6 months ago
0.2.2
6 months ago
0.0.2
11 months ago
0.0.1
11 months ago