You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/routes/reference/reactive-utilities/untrack.mdx
+9-12Lines changed: 9 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,13 +19,12 @@ description: >-
19
19
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.
20
20
21
21
```tsx title="component.tsx"
22
-
import { untrack } from"solid-js"
22
+
import { untrack } from"solid-js";
23
23
24
24
exportfunction Component(props) {
25
-
const value =untrack(() =>props.value)
25
+
const value =untrack(() =>props.value);
26
26
27
-
return <div>{value}</div>
28
-
}
27
+
return <div>{value}</div>;
29
28
}
30
29
```
31
30
@@ -35,24 +34,22 @@ It is not necessary to manually untrack values that are suppose to serve as a de
0 commit comments