Skip to content

Commit

Permalink
docs tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
bholmesdev committed Jul 22, 2024
1 parent 0b6eeb4 commit 8208d83
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions packages/query/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ $<HTMLInputElement>('input').value = '';

### `$.optional()` selector

`$()` throws when no matching element is found. To avoid this behavior, use `$.optional()`:
`$()` throws when no matching element is found. To handle undefined values, use `$.optional()`:

```astro
---
Expand Down Expand Up @@ -87,7 +87,7 @@ ready(() => {
</script>
```

## Global `$.ready()` function
### `$.ready()` function

All `$` queries must be nested in a `$.ready()` block. This opts in to using the global `$` from client scripts. `$.ready()` also ensures your code reruns on every page [when view transitions are enabled.](https://docs.astro.build/en/guides/view-transitions/)

Expand Down
4 changes: 2 additions & 2 deletions www/src/content/docs/query.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ $<HTMLInputElement>('input').value = '';

### `$.optional()` selector

`$()` throws when no matching element is found. To avoid this behavior, use `$.optional()`:
`$()` throws when no matching element is found. To handle undefined values, use `$.optional()`:

```astro
---
Expand Down Expand Up @@ -90,7 +90,7 @@ ready(() => {
</script>
```

## Global `$.ready()` function
## `$.ready()` function

All `$` queries must be nested in a `$.ready()` block. This opts in to using the global `$` from client scripts. `$.ready()` also ensures your code reruns on every page [when view transitions are enabled.](https://docs.astro.build/en/guides/view-transitions/)

Expand Down

0 comments on commit 8208d83

Please sign in to comment.