counter.tsx 287 B

1234567891011121314
  1. "use client";
  2. import { useState } from "react";
  3. import { Button } from "@nextui-org/button";
  4. export const Counter = () => {
  5. const [count, setCount] = useState(0);
  6. return (
  7. <Button radius="full" onPress={() => setCount(count + 1)}>
  8. Count is {count}
  9. </Button>
  10. );
  11. };