aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Colin McDonnell <colinmcd94@gmail.com> 2023-07-25 12:27:22 -0700
committerGravatar Colin McDonnell <colinmcd94@gmail.com> 2023-07-25 12:27:27 -0700
commit6bfee02301a2e2a0b79339974af0445eb5a2688f (patch)
tree70414b69a835654bb244cfef9ac657202a7bb3f3
parent0297cb15271e309acb543896f24f4ddac9833428 (diff)
downloadbun-6bfee02301a2e2a0b79339974af0445eb5a2688f.tar.gz
bun-6bfee02301a2e2a0b79339974af0445eb5a2688f.tar.zst
bun-6bfee02301a2e2a0b79339974af0445eb5a2688f.zip
Fix typo
-rw-r--r--docs/runtime/jsx.md20
1 files changed, 17 insertions, 3 deletions
diff --git a/docs/runtime/jsx.md b/docs/runtime/jsx.md
index ae0a319db..ecf250c82 100644
--- a/docs/runtime/jsx.md
+++ b/docs/runtime/jsx.md
@@ -67,7 +67,14 @@ How JSX constructs are transformed into vanilla JavaScript internally. The table
- ```tsx
import { jsxDEV } from "react/jsx-dev-runtime";
- jsxDEV("Box", { width: 5, children: "Hello" }, undefined, false, undefined, this);
+ jsxDEV(
+ "Box",
+ { width: 5, children: "Hello" },
+ undefined,
+ false,
+ undefined,
+ this,
+ );
```
The `jsxDEV` variable name is a convention used by React. The `DEV` suffix is a visible way to indicate that the code is intended for use in development. The development version of React is slowers and includes additional validity checks & debugging tools.
@@ -133,7 +140,7 @@ The function name used to represent JSX constructs. Default value is `"createEle
```
- ```tsx
- import { createhElement } from "react";
+ import { h } from "react";
h("Box", { width: 5 }, "Hello");
```
@@ -227,7 +234,14 @@ The module from which the component factory function (`createElement`, `jsx`, `j
- ```tsx
// /jsx-runtime is automatically appended
import { jsxDEV } from "preact/jsx-dev-runtime";
- jsxDEV("Box", { width: 5, children: "Hello" }, undefined, false, undefined, this);
+ jsxDEV(
+ "Box",
+ { width: 5, children: "Hello" },
+ undefined,
+ false,
+ undefined,
+ this,
+ );
```
{% /table %}