Skip to content

Commit

Permalink
fix: small refinements
Browse files Browse the repository at this point in the history
  • Loading branch information
leweyse committed Dec 27, 2024
1 parent aca6816 commit 0c41dbe
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 7 deletions.
20 changes: 20 additions & 0 deletions examples/starter/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Starter [![Open in StackBlitz](https://img.shields.io/badge/Open%20in-StackBlitz-blue?style=flat-square&logo=stackblitz)](https://stackblitz.com/github/pmndrs/valtio/tree/main/examples/starter)

## Set up locally

```bash
git clone https://github.com/pmndrs/valtio

# install project dependencies & build the library
cd valtio && pnpm install

# move to the examples folder & install dependencies
cd examples/starter && pnpm install

# start the dev server
pnpm dev
```

## Set up on `StackBlitz`

Link: https://stackblitz.com/github/pmndrs/valtio/tree/main/examples/starter
4 changes: 2 additions & 2 deletions examples/starter/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<script src="https://cdn.tailwindcss.com"></script>
</head>
<body>
<div id="app"></div>
<script type="module" src="/src/app.tsx"></script>
<div id="root"></div>
<script type="module" src="/src/index.tsx"></script>
</body>
</html>
4 changes: 2 additions & 2 deletions examples/starter/src/index.css
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
html,
body,
#app {
#root {
height: 100%;
}

#app {
#root {
display: flex;
place-items: center;
justify-content: center;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,7 @@ function App() {
);
}

const root = document.getElementById('app');

createRoot(root!).render(
createRoot(document.getElementById('root')!).render(
<StrictMode>
<App />
</StrictMode>,
Expand Down

0 comments on commit 0c41dbe

Please sign in to comment.