Skip to content

Commit

Permalink
fix(create-mud): workaround create-create-app templating (#1863)
Browse files Browse the repository at this point in the history
  • Loading branch information
holic authored Nov 2, 2023
1 parent 6288f90 commit 1b33a91
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/purple-ghosts-hear.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"create-mud": patch
---

Fixed an issue when creating a new project from the `react` app, where React's expressions were overlapping with Handlebars expressions (used by our template command).
6 changes: 4 additions & 2 deletions templates/react/packages/client/src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
import { useMUD } from "./MUDContext";

const styleUnset = { all: "unset" } as const;

export const App = () => {
const {
network: { tables, useStore },
Expand Down Expand Up @@ -41,7 +43,7 @@ export const App = () => {
<button
type="button"
title="Delete task"
style={{ all: "unset" }}
style={styleUnset}
onClick={async (event) => {
event.preventDefault();
if (!window.confirm("Are you sure you want to delete this task?")) return;
Expand Down Expand Up @@ -87,7 +89,7 @@ export const App = () => {
}
}}
>
<fieldset style={{ all: "unset" }}>
<fieldset style={styleUnset}>
<input type="text" name="description" />{" "}
<button type="submit" title="Add task">
Add
Expand Down

0 comments on commit 1b33a91

Please sign in to comment.