Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
abhishiv authored Jul 2, 2024
1 parent 76394d3 commit d069036
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,17 +55,16 @@ const Page = component("HomePage", (props, { signal, wire, store }) => {
// with explicit subscription using the $ token param
// Easy to reason about and no untrack/sample related errors
const $doubleCount = wire(($) => $count($) * 2);
return (
return (
<div id="home">
<p>Hey, {props.name}</p>
<button onClick={() => $count($count() + 1)}>
Increment / {wire($count)}
</button>
<p>Double count = {$doubleCount}</p>
</div>
);
}
);
);
});

render(<Page name="John Doe" />, document.body);
```
Expand Down

0 comments on commit d069036

Please sign in to comment.