Skip to content

Commit cb77df9

Browse files
PrincesseuhElianCodessarah11918
authored
Apply suggestions from code review
Co-authored-by: Elian <[email protected]> Co-authored-by: Sarah Rainsberger <[email protected]>
1 parent fbf3c12 commit cb77df9

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/content/blog/astro-440.mdx

+6-6
Original file line numberDiff line numberDiff line change
@@ -49,17 +49,17 @@ Astro 4.4 includes the addition of performance audits for the dev toolbar. Much
4949

5050
## Audit list
5151

52-
Starting from Astro 4.4, the dev toolbar's audit app includes a small UI showing the list of problems that have been detected. This list is a great way to quickly see what issues need to be addressed, and to jump to the relevant part of the page to fix them. In the future, we'll be expanding this UI to show more information about each issue, and to provide more guidance on how to fix them.
52+
Starting from Astro 4.4, the dev toolbar's audit app includes a small UI showing the list of problems that have been detected. This list is a great way to quickly see what issues need to be addressed and to jump to the relevant part of the page to fix them. In the future, we'll be expanding this UI to show more information about each issue, and to provide more guidance on how to fix them.
5353

5454
## Improved streaming performance
5555

5656
This release includes performance improvements for streaming. We discovered recently that `ReadableStream`s were slower than expected on Node.js, and migrated Astro to use `AsyncIterable` instead when running on Node.js. Notably, this change reduced the build time of Starlight websites with large sidebars by up to 47% in extreme cases. For more technical details, check out the [pull request](https://github.com/withastro/astro/pull/9614) for this change.
5757

58-
No changes are required to take advantage of these improvements, which benefits both static builds and runtime performance, but you may notice faster build times and improved runtime performance, as a treat.
58+
No changes are required to take advantage of these improvements, which benefit both static builds and runtime performance. You can have faster build times and improved runtime performance, as a treat.
5959

6060
## Automatically infer dimensions of remote images
6161

62-
Thanks to [Oliver Speir](https://github.com/OliverSpeir), Astro 4.4 can now automatically infer the dimensions of remote images, which means you no longer need to specify the `width` and `height` attributes for remote images. This is especially useful when working with images from a CMS or other external sources where the dimensions of the image are not known at build time.
62+
Thanks to [Oliver Speir](https://github.com/OliverSpeir), Astro 4.4 can now infer the dimensions of remote images. The new `inferSize` attribute can be used as a replacement for the previously required `width` and `height` attributes on remote images. This is especially useful when working with images from a CMS or other external sources where the dimensions of the image are not known at build time.
6363

6464
To enable this feature, set the `inferSize` prop to `true` on the `Image` or `Picture` components:
6565

@@ -68,11 +68,11 @@ To enable this feature, set the `inferSize` prop to `true` on the `Image` or `Pi
6868
import { Image, Picture } from "astro:assets";
6969
---
7070
71-
<Image src="https://example.com/image.jpg" alt="A cool image" inferSize={true} />
72-
<Picture src="https://example.com/image.jpg" alt="A cool image" inferSize={true} />
71+
<Image src="https://example.com/image.jpg" alt="A cool image" inferSize />
72+
<Picture src="https://example.com/image.jpg" alt="A cool image" inferSize />
7373
```
7474

75-
or as a parameter to `getImage`:
75+
or as a parameter to `getImage()`:
7676

7777
```ts
7878
import { getImage } from "astro:assets";

0 commit comments

Comments
 (0)