Skip to content

Commit 4c6d2c6

Browse files
committed
docs: correct spelling mistakes and other issues, improve syntax
1 parent da3a773 commit 4c6d2c6

File tree

12 files changed

+55
-55
lines changed

12 files changed

+55
-55
lines changed

docs/pages/available-options.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ These are the options that can be used to transform images with this package.
66

77
`string`
88

9-
Set the background color of the image.
9+
Set the background color of the image.
1010
Any valid HEX color value (without a leading `#`).
1111

1212
Example:
@@ -38,7 +38,7 @@ blur=50
3838

3939
`integer`
4040

41-
Set the contrast level of the image.
41+
Set the contrast level of the image.
4242
Possible values: `-100` to `100`.
4343

4444
Example:
@@ -51,7 +51,7 @@ contrast=50
5151

5252
`string`
5353

54-
Flip the image.
54+
Flip the image.
5555
Possible values: `h` (horizontal), `v` (vertical), `hv` (horizontal and vertical).
5656

5757
Example:
@@ -64,7 +64,7 @@ flip=h
6464

6565
`string`
6666

67-
Set the format of the image.
67+
Set the format of the image.
6868
Supported formats: `jpg`, `jpeg`, `png`, `gif`, `webp`.
6969

7070
Example:
@@ -77,7 +77,7 @@ format=webp
7777

7878
`integer`
7979

80-
Set the height of the image.
80+
Set the height of the image.
8181
Values greater than the original height will be ignored.
8282

8383
Example:
@@ -90,7 +90,7 @@ height=250
9090

9191
`integer`
9292

93-
Set the quality of the image.
93+
Set the quality of the image.
9494
Possible values: `0` to `100`.
9595

9696
Example:
@@ -103,7 +103,7 @@ quality=80
103103

104104
`integer`
105105

106-
Version number of the image.
106+
Version number of the image.
107107
Any positive integer. More info in the [Image Caching](/image-caching) section.
108108

109109
Example:
@@ -116,7 +116,7 @@ version=2
116116

117117
`integer`
118118

119-
Set the width of the image.
119+
Set the width of the image.
120120
Values greater than the original width will be ignored.
121121

122122
Example:

docs/pages/cdn-usage.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
The package is designed to work seamlessly with CDNs like Cloudflare, BunnyCDN, and others.
44

5-
The most important configuration is the [`Cache-Control`](https://developer.mozilla.org/de/docs/Web/HTTP/Reference/Headers/Cache-Control) header, which you can customize to your liking in the `image-transform-url.php` configuration file.
5+
The most important configuration is the [`Cache-Control`](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control) header, which you can customize in the `image-transform-url.php` configuration file.
66

77
```php
88
/*

docs/pages/configuring-options.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Configuring Options
22

3-
This package supports a variety of options, but you may not need or want to use all of them. You can configure which options are enabled in the `image-transform-url.php` configuration file.
3+
This package supports a variety of options, but you may not need all of them. You can configure which options are enabled in the `image-transform-url.php` configuration file.
44

55
```php
66
/*

docs/pages/error-handling.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
11
# Error Handling
22

3-
The route handler of this package is designed to be robust against invalid options, paths and file names, while also not exposing additional information of your applications public directory structure.
3+
The route handler of this package is designed to be robust against invalid options, paths, and file names, while also not exposing additional information about your application's public directory structure.
44

55
## HTTP Status Codes
66

7-
This is why the route handler will return a plain `404` response if:
7+
For this reason, the route handler returns a plain `404` response if:
88

9-
- a requested image does not exist at the specified path
10-
- the requested image is not a valid image file
9+
- the requested image does not exist at the specified path
10+
- the requested file is not a valid image
1111
- the provided options are not in the correct format (`key=value`, no trailing comma, etc.)
1212

1313
The only two other HTTP errors that can be returned are:
1414
- a `429` response, which indicates that the request was rate-limited
15-
- a `403` response, which indicates that the request was unauthorized (e.g. when using signed URLs and the signature is invalid or expired)
15+
- a `403` response, which indicates that the request was unauthorized (e.g., when using signed URLs and the signature is invalid or expired)
1616

1717
## Invalid options
1818

19-
If parts of the given route options are invalid, the route handler will ignore them and only apply the valid options.
19+
If parts of the given route options are invalid, the route handler ignores them and applies only the valid options.
2020

2121
Example:
2222

docs/pages/getting-started.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,15 @@ For example:
1717
http://localhost:8000/image-transform/width=250,quality=80,format=webp/foo/bar/example.jpg
1818
```
1919

20-
With a `source-directory`, respectively:
20+
With a `source-directory`:
2121

2222
```ansi
2323
http://localhost:8000/image-transform/images/width=250,quality=80,format=webp/foo/bar/example.jpg
2424
```
2525

2626
## Programmatic URL Generation
2727

28-
While you can construct URLs manually when you need it, the package provides convenient methods to generate transformation URLs programmatically using the `ImageTransformUrl` facade.
28+
While you can construct URLs manually when needed, the package provides convenient methods to generate transformation URLs programmatically using the `ImageTransformUrl` facade.
2929

3030
Use the `make()` method to generate regular transformation URLs:
3131

docs/pages/image-caching.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
# Image Caching
22

3-
This package comes with the default option to automatically store and serve images statically for the requested options within the caching lifetime.
3+
This package can automatically store and serve images statically for the requested options within the caching lifetime.
44

55
> [!INFO]
6-
> Having this feature enabled (default behavior) will help to reduce the load on your server and speed up image delivery.
6+
> Enabling this feature (default) reduces server load and speeds up image delivery.
77
88
The processed images are stored in the `storage/app/private/_cache/image-transform-url` directory by default. You can change the disk configuration in the `image-transform-url.php` configuration file.
99

@@ -12,19 +12,19 @@ The processed images are stored in the `storage/app/private/_cache/image-transfo
1212
>
1313
> **Source images are considered to be stale content by their file name and path.**
1414
15-
If the content of an original source image changes, but the file name stays the same, the cached images will not be updated automatically until the cache expires.
15+
If the content of a source image changes but the file name stays the same, the cached images will not be updated automatically until the cache expires.
1616
To force a revalidation, you can either:
1717

1818
1. change the image's file name
1919
2. move it into another subdirectory, which will change its path
20-
3. change the [version number](/available-options#version) in the options (e.g. `version=2`)
20+
3. change the [version number](/available-options#version) in the options (e.g., `version=2`)
2121
4. or flush the entire cache of your application using the `php artisan cache:clear` command.
2222

2323
## Cache Size Limit
2424

25-
The image caching feature also comes with a size limit to prevent the cache from growing indefinitely. The default maximum size is set to **100 MB**, but you can change this in the configuration file.
25+
The image caching feature also includes a size limit to prevent the cache from growing indefinitely. The default maximum size is **100 MB**, but you can change this in the configuration file.
2626

27-
When the cache reaches the specified size limit, it will automatically clean up old files to make space for new ones.
27+
When the cache reaches the specified size limit, it automatically cleans up old files to make space for new ones.
2828

2929
You may also configure the percentage of the maximum size that should be kept after cleanup, referred to as `clear_to_percent`.
3030
For example, if `clear_to_percent` is set to 80, 20% of the cache is cleared on each cleanup run, and 80% is retained. The default is set to 80% of the maximum size.

docs/pages/index.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,11 @@ hero:
1515

1616
features:
1717
- title: ✈️ On-the-fly
18-
details: Use URL parameters to transform images on the fly
18+
details: Transform images on the fly via URL parameters
1919
- title: 🔧 Versatile
20-
details: Support various transformations, S3 storage and signed URLs
20+
details: Supports various transformations, S3 storage, and signed URLs
2121
- title: ⚡ Fast and Efficient
22-
details: Automatic caching of transformed images for faster loading times
22+
details: Automatic caching of transformed images for faster load times
2323
- title: 🌍 CDN Ready
24-
details: Easy integration with CDNs for even faster global delivery
24+
details: Easy CDN integration for faster global delivery
2525
---

docs/pages/installation.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
- [GD](https://www.php.net/manual/en/book.image.php) or [Imagick](https://www.php.net/manual/en/book.imagick.php) PHP extension installed and [enabled](#driver-configuration)
88

99
::: tip
10-
If you want to use the file caching feature (highly recommended), a configured `Storage` disk and a `Cache` driver is required. More info in the [Image Caching](/image-caching) section.
10+
If you want to use the file caching feature (highly recommended), a configured `Storage` disk and a `Cache` driver are required. More info in the [Image Caching](/image-caching) section.
1111
:::
1212

1313
## Installation
@@ -26,7 +26,7 @@ php artisan vendor:publish --tag="image-transform-url-config"
2626

2727
## Driver Configuration
2828

29-
To use Imagick instead of the default GD library for image processing (recommended for performance), you will have to [change the default image driver](https://image.intervention.io/v3/getting-started/frameworks#application-wide-configuration) for the underlying [Intervention Image](https://image.intervention.io/) package.
29+
To use Imagick instead of the default GD library for image processing (recommended for performance), you must [change the default image driver](https://image.intervention.io/v3/getting-started/frameworks#application-wide-configuration) for the underlying [Intervention Image](https://image.intervention.io/) package.
3030

3131
::: info
3232
The [`libvips` driver](https://github.com/Intervention/image-driver-vips) is currently not supported.
@@ -36,11 +36,11 @@ The [`libvips` driver](https://github.com/Intervention/image-driver-vips) is cur
3636

3737
Depending on your environment, you may need to adjust some `php.ini` settings.
3838

39-
1. If you are using the default GD driver, be aware that it can use alot more RAM than regular web requests. It's highly recommended to set your memory limit to *at least* 256MB.
39+
1. If you are using the default GD driver, be aware that it can use alot more RAM than regular web requests. It's highly recommended to set your memory limit to *at least* 256 MB.
4040
```
4141
memory_limit=512M
4242
```
43-
2. If you have the [Swoole extension](https://laravel.com/docs/octane#swoole) installed, make sure you have the following setting to [avoid conflicts](https://github.com/ace-of-aces/laravel-image-transform-url/issues/4) with Laravel's `defer` helper which this package uses.
43+
2. If you have the [Swoole extension](https://laravel.com/docs/octane#swoole) installed, ensure you have the following setting to [avoid conflicts](https://github.com/ace-of-aces/laravel-image-transform-url/issues/4) with Laravel's `defer` helper, which this package uses.
4444
```
4545
swoole.use_shortname=off
4646
```

docs/pages/rate-limiting.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11
# Rate Limiting
22

3-
Another feature of this package is the ability to limit the number of transformations that the image transformation route should process **per path and IP address** within a given time frame.
3+
This package can limit the number of transformations the image transformation route processes **per path and IP address** within a given time frame.
44

5-
The rate limit will come into effect for new transformation requests only, and will not affect previously cached images.
5+
The rate limit applies only to new transformation requests and does not affect previously cached images.
66

7-
By default, rate limiting is disabled for the `local` and `testing` app environements to not distract you when developing your app. You can configure the rate limit settings in the `image-transform-url.php` configuration file.
7+
By default, rate limiting is disabled for the `local` and `testing` app environments so it doesn't distract you during development. You can configure the rate limit settings in the `image-transform-url.php` configuration file.
88

99
```php
1010
/*
1111
|--------------------------------------------------------------------------
1212
| Rate Limit
1313
|--------------------------------------------------------------------------
1414
|
15-
| Below you may configure the rate limit which is applied for each image
16-
| new transformation by the path and IP address. It is recommended to
17-
| set this to a low value, e.g. 2 requests per minute, to prevent
18-
| abuse.
15+
| Below you may configure the rate limit applied to each image transformation
16+
| by path and IP address. It is recommended to set this to a low value,
17+
| e.g. 2 requests per minute, to prevent abuse.
18+
|
1919
*/
2020
'rate_limit' => [
2121
'enabled' => env('IMAGE_TRANSFORM_RATE_LIMIT_ENABLED', true),

docs/pages/s3-usage.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
# Usage with S3
22

33
This guide explains how to configure this package to work with S3-compatible storage services like AWS S3 or Cloudflare R2.
4-
This enables you to transform and serve images stored remotely without the need to store images on your local server.
4+
This lets you transform and serve images stored remotely without the need to store them on your local server.
55

6-
1. Set up your S3 disk in your [filesystems configuration](https://laravel.com/docs/filesystem#amazon-s3-compatible-filesystems), install the [S3 package](https://laravel.com/docs/filesystem#s3-driver-configuration) and ensure you have the necessary credentials and settings for your S3 bucket. Public bucket access is not required.
6+
1. Set up your S3 disk in your [filesystems configuration](https://laravel.com/docs/filesystem#amazon-s3-compatible-filesystems), install the [S3 package](https://laravel.com/docs/filesystem#s3-driver-configuration), and ensure you have the necessary credentials and settings for your S3 bucket. Public bucket access is not required.
77

88
2. Configure the package via `image-transform-url.php` to include your S3 disk in the `source_directories` as described in [the setup guide](/setup#configuring-remote-sources).
99

10-
3. If you are using the [Image Caching](/image-caching) feature and want to store transformed images back to your S3 bucket instead of your local filesystem, you may also set the `cache.disk` option in the `image-transform-url.php` configuration file to your S3 disk.
10+
3. If you are using the [Image Caching](/image-caching) feature and want to store transformed images back to your S3 bucket instead of your local filesystem, set the `cache.disk` option in the `image-transform-url.php` configuration file to your S3 disk.
1111

1212
```php
1313
'cache' => [

0 commit comments

Comments
 (0)