@leva-ui/plugin-plot

npm i @leva-ui/plugin-plot

Usage no npm install needed!

<script type="module">
  import levaUiPluginPlot from 'https://cdn.skypack.dev/@leva-ui/plugin-plot';
</script>

README

Leva Plot

Installation

npm i @leva-ui/plugin-plot

Quick start

import { useControls } from "leva"
import { plot } from "@leva-ui/plugin-plot"

function MyComponent() {
  const { y } = useControls({ y: plot({ expression: 'cos(x)', graph: true, boundsX: [-10,10], boundsY: [0, 100] }) })
  return y(Math.PI)
}