Skip to content

Commit e6bbf39

Browse files
authored
fix: revisit public apis (#820)
1 parent fec641f commit e6bbf39

File tree

20 files changed

+61
-426
lines changed

20 files changed

+61
-426
lines changed

packages/docs/src/pages/tutorial/events/programmatic/index.mdx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@ Qwik provides the following functions to attach a listener:
1212
| `useOn()` | Add an event on specific event on current host element. |
1313
| `useOnDocument()` | Add an event on specific event on document. |
1414
| `useOnWindow()` | Add an event on specific event on window. |
15-
| `useVisible$()` | Invoked when component becomes visible. |
16-
| `useResume$()` | Invoked eagerly as the application loads. |
1715

1816
> **Your task**: Set up a click listener on the component to call `alert('Hello world!')`.
1917

packages/docs/src/pages/tutorial/hooks/use-client-effect/index.mdx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,8 @@ title: useClientEffect$()
33
layout: tutorial
44
---
55

6-
Use `useClientEffect$()` to execute code after the component is resumed. This is useful for setting up timers or streams on the client when the application is resumed.
6+
Use `useClientEffect$()` to execute code after the component is resumed. This is useful for setting up timers or streams on the client when the application is resumed.
77

8-
NOTE: `useClientEffect$()` is similar to `useResume$()` but `useClientEffect$()` can be invoked multiple times. `useClientEffect$()` can be re-triggered as port of the `track` of store.
98

109
## `track()` and `useClientEffect$()`
1110

@@ -27,7 +26,7 @@ Client effect code is executed after the component is resumed. The `useClientEff
2726

2827
## Example
2928

30-
The example shows a clock component that is rendered below the fold. Use the `useClientEffect$()` to make the clock update the current time every second to make it work on the client. We have provided the utility function `updateClock` to aid your implementation.
29+
The example shows a clock component that is rendered below the fold. Use the `useClientEffect$()` to make the clock update the current time every second to make it work on the client. We have provided the utility function `updateClock` to aid your implementation.
3130

3231
Keep in mind that `useClientEffect$()` should return a cleanup function that releases the `setInterval` timer so that the timer can be properly cleaned up when the component is unmounted/destroyed.
3332

packages/docs/src/pages/tutorial/hooks/use-resume/index.mdx

Lines changed: 0 additions & 17 deletions
This file was deleted.

packages/docs/src/pages/tutorial/hooks/use-resume/problem/app.tsx

Lines changed: 0 additions & 22 deletions
This file was deleted.

packages/docs/src/pages/tutorial/hooks/use-resume/solution/app.tsx

Lines changed: 0 additions & 22 deletions
This file was deleted.

packages/docs/src/pages/tutorial/hooks/use-wait-on/index.mdx

Lines changed: 0 additions & 14 deletions
This file was deleted.

packages/docs/src/pages/tutorial/hooks/use-wait-on/problem/app.tsx

Lines changed: 0 additions & 28 deletions
This file was deleted.

packages/docs/src/pages/tutorial/hooks/use-wait-on/solution/app.tsx

Lines changed: 0 additions & 28 deletions
This file was deleted.

packages/docs/src/pages/tutorial/hooks/use-watch/index.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: useWatch$()
33
layout: tutorial
44
---
55

6-
Use `useWatch$()` to execute a function before the initial render and whenever the tracking values change. The function executes before rendering, but it can't delay rendering, so if `useWatch$()` is asynchronous, the rendering will happen before the `useWatch$()` is fully executed. If you need to delay rendering, see [`useWaitOn()`](/tutorial/hooks/use-wait-on).
6+
Use `useWatch$()` to execute a function before the initial render and whenever the tracking values change. The function executes before rendering, but it can't delay rendering, so if `useWatch$()` is asynchronous, the rendering will happen before the `useWatch$()` is fully executed.
77

88
## Tracking store changes
99

packages/docs/src/pages/tutorial/tutorial-menu.json

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -268,13 +268,6 @@
268268
"enableClientOutput": false,
269269
"enableSsrOutput": false
270270
},
271-
{
272-
"id": "use-wait-on",
273-
"title": "useWaitOn()",
274-
"enableHtmlOutput": false,
275-
"enableClientOutput": false,
276-
"enableSsrOutput": false
277-
},
278271
{
279272
"id": "use-ref",
280273
"title": "useRef()",
@@ -296,13 +289,6 @@
296289
"enableClientOutput": false,
297290
"enableSsrOutput": false
298291
},
299-
{
300-
"id": "use-resume",
301-
"title": "useResume$()",
302-
"enableHtmlOutput": true,
303-
"enableClientOutput": true,
304-
"enableSsrOutput": true
305-
},
306292
{
307293
"id": "use-on",
308294
"title": "useOn() / useOnDocument() / useOnWindow()",

0 commit comments

Comments
 (0)