21 lines
328 B
TypeScript
21 lines
328 B
TypeScript
import { useCounterStore } from "./stores/counterStore";
|
|
|
|
function App() {
|
|
const { count, incr } = useCounterStore();
|
|
|
|
return (
|
|
<>
|
|
<p>Hello World!</p>
|
|
<p>Count: {count}</p>
|
|
<button
|
|
className="p-2 bg-red-400 rounded text-white"
|
|
onClick={incr}
|
|
>
|
|
Increment
|
|
</button>
|
|
</>
|
|
);
|
|
}
|
|
|
|
export default App;
|