Skip to content

GridLines

Open .md
Live preview

Loading example…

Soft background lines; the zero line, when visible, is a little stronger.

import { GridLines } from "@jcsoftdev/ui/charts";

Single-component entry points tree-shake to just this component: @jcsoftdev/ui/charts/core.

export const Default: Story = {
render: () => <AxesDemo title="Ventas" rightTitle="Cortes" showRight={false} showGrid />,
};

Source of the Storybook story.

Prop Type Default Description
ticks * readonly AxisTick[]
direction * "horizontal" | "vertical" Lines across the plot: horizontal for a vertical value axis.
length * number Plot width (horizontal lines) or height (vertical lines).
zero number Position of the zero line, drawn stronger.

* marks a required prop.

packages/ui/src/charts/core/axes.tsx