@pingcap-incubator/statement
v0.0.9
Published
>
Downloads
9
Readme
@pingcap-incubator/statement
Install
npm install --save @pingcap-incubator/statement
Usage
import React from 'react'
import { HashRouter as Router } from 'react-router-dom'
import { StatementsOverviewPage } from '@pingcap-incubator/statement'
import * as DashboardClient from '@pingcap-incubator/dashboard_client'
const dashboardClient = new DashboardClient.DefaultApi({
basePath: 'http://127.0.0.1:12333/dashboard/api',
apiKey: 'xxx',
})
const App = () => (
<Router>
<div style={{ margin: 12 }}>
<StatementsOverviewPage
dashboardClient={dashboardClient}
detailPagePath="/statement/detail"
/>
</div>
</Router>
)
export default App
More usage, see demo