diff --git a/src/routes/reference/reactive-utilities/untrack.mdx b/src/routes/reference/reactive-utilities/untrack.mdx
index e33e99d4e..2b38a9383 100644
--- a/src/routes/reference/reactive-utilities/untrack.mdx
+++ b/src/routes/reference/reactive-utilities/untrack.mdx
@@ -19,13 +19,12 @@ description: >-
Ignores tracking any of the dependencies in the executing code block and returns the value. This helper is useful when a certain `prop` will never update and thus it is ok to use it outside of the tracking scope.
```tsx title="component.tsx"
-import { untrack } from "solid-js"
+import { untrack } from "solid-js";
export function Component(props) {
- const value = untrack(() => props.value)
+ const value = untrack(() => props.value);
- return
{value}
- }
+ return {value}
;
}
```
@@ -35,24 +34,22 @@ It is not necessary to manually untrack values that are suppose to serve as a de
```tsx tab title="initialValue" {5}
// component.tsx
-import { createSignal } from "solid-js"
+import { createSignal } from "solid-js";
export function Component(props) {
- const [name, setName] = createSignal(props.initialName)
+ const [name, setName] = createSignal(props.initialName);
- return {name()}
- }
+ return {name()}
;
}
```
```tsx tab title="defaultValue" {5}
// component.tsx
-import { createSignal } from "solid-js"
+import { createSignal } from "solid-js";
export function Component(props) {
- const [name, setName] = createSignal(props.defaultName)
+ const [name, setName] = createSignal(props.defaultName);
- return {name()}
- }
+ return {name()}
;
}
```