diff options
Diffstat (limited to 'examples/with-nanostores/src/components/AddToCartForm.tsx')
-rw-r--r-- | examples/with-nanostores/src/components/AddToCartForm.tsx | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/examples/with-nanostores/src/components/AddToCartForm.tsx b/examples/with-nanostores/src/components/AddToCartForm.tsx index 2f1befb9f..7498443f6 100644 --- a/examples/with-nanostores/src/components/AddToCartForm.tsx +++ b/examples/with-nanostores/src/components/AddToCartForm.tsx @@ -5,7 +5,7 @@ import type { ComponentChildren } from 'preact'; type Props = { item: CartItemDisplayInfo; children: ComponentChildren; -} +}; export default function AddToCartForm({ item, children }: Props) { function addToCart(e: SubmitEvent) { @@ -14,9 +14,5 @@ export default function AddToCartForm({ item, children }: Props) { addCartItem(item); } - return ( - <form onSubmit={addToCart}> - {children} - </form> - ) + return <form onSubmit={addToCart}>{children}</form>; } |