How to use the @nivo/axes.AxisLegendPosition.Middle function in @nivo/axes

To help you get started, we’ve selected a few @nivo/axes examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github plouc / nivo / examples / typescript / src / components / Bar.tsx View on Github external
indexBy="id"
                    keys={['a', 'b', 'c']}
                    maxValue={4}
                    margin={{
                        top: 10,
                        right: 120,
                        bottom: 40,
                        left: 40,
                    }}
                    padding={.3}
                    axisLeft={{
                        tickValues: 5,
                    }}
                    axisBottom={{
                        legend: 'THINGS',
                        legendPosition: AxisLegendPosition.Middle,
                        legendOffset: 36 
                    }}
                    markers={[
                        {
                            crap: true
                        }
                    ]}
                    legends={[
                        {
                            dataFrom: 'keys',
                            anchor: LegendAnchor.BottomRight,
                            direction: LegendDirection.Column,
                            itemWidth: 100,
                            itemHeight: 32,
                            translateX: 120,
                        }

@nivo/axes

<a href="https://nivo.rocks"><img alt="nivo" src="https://raw.githubusercontent.com/plouc/nivo/master/nivo.png" width="216" height="68"/></a>

MIT
Latest version published 5 days ago

Package Health Score

95 / 100
Full package analysis