Skip to content

Commit

Permalink
Update README.md (#539)
Browse files Browse the repository at this point in the history
  • Loading branch information
keller-mark authored Apr 14, 2024
1 parent f5ab13e commit dcbf443
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/react/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@ import { createRender, useModelState } from "@anywidget/react";

function Counter() {
let [value, setValue] = useModelState("value");
return <button onClick={() => setValue(value + 1)}>count is {count}</button>;
return <button onClick={() => setValue(value + 1)}>count is {value}</button>;
}

export let render = createRender(Counter);
const render = createRender(Counter);

export default { render };
```

## License
Expand Down

0 comments on commit dcbf443

Please sign in to comment.