Skip to content

Commit a04b483

Browse files
authored
docs: fix grammatical errors and improve clarity (#838)
* fix typo * fix grammatical error * add important punctuations between sentences * improve passive sentence * add "the" to refer to specific entry point * fix compound words * fix phrasal verbs * fix official naming for Node.js, JavaScript, TypeScript and remove unnecessary line-spacing between words in a sentence. * fix punctuation between sentences * fix grammatical error * fix official naming for HTML * fix parallel structure in sentences and remove unnecessary line-spacing between words * fix subject-verb agreement * improve instruction * replace with a better conjunction * add punctuation between sentences * add punctuation, fix official naming for CSS * fix official naming for CSS * improve sentence clarity
1 parent fc78fb1 commit a04b483

25 files changed

Lines changed: 65 additions & 81 deletions

docs/api/context.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ const app = new Hono()
4545
app.get('/', (c) => {
4646
// Set headers
4747
c.header('X-Message', 'My custom message')
48-
return c.text('HellO!')
48+
return c.text('Hello!')
4949
})
5050
```
5151

@@ -96,7 +96,7 @@ new Response('Thank you for coming', {
9696

9797
## text()
9898

99-
Render text as `Content-Type:text/plain`.
99+
Render text as `Content-Type: text/plain`.
100100

101101
```ts twoslash
102102
import { Hono } from 'hono'
@@ -109,7 +109,7 @@ app.get('/say', (c) => {
109109

110110
## json()
111111

112-
Render JSON as `Content-Type:application/json`.
112+
Render JSON as `Content-Type: application/json`.
113113

114114
```ts twoslash
115115
import { Hono } from 'hono'
@@ -122,7 +122,7 @@ app.get('/api', (c) => {
122122

123123
## html()
124124

125-
Render HTML as `Content-Type:text/html`.
125+
Render HTML as `Content-Type: text/html`.
126126

127127
```ts twoslash
128128
import { Hono } from 'hono'

docs/api/exception.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ You can throw your own HTTPExceptions by specifying a status code, and either a
88

99
### Custom Message
1010

11-
For basic `text` responses, just set a the error `message`.
11+
For basic `text` responses, just set the error `message`.
1212

1313
```ts twoslash
1414
import { HTTPException } from 'hono/http-exception'

docs/api/hono.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ addEventListener('fetch', (event: FetchEventLike): void => {
8686

8787
## fetch()
8888

89-
`app.fetch` will be entry point of your application.
89+
`app.fetch` will be the entry point of your application.
9090

9191
For Cloudflare Workers, you can use the following:
9292

docs/api/request.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ body['foo[]']
140140

141141
### Multiple files or fields with same name
142142

143-
If you have a input field that allows multiple `<input type="file" multiple />` or multiple checkboxes with the same name `<input type="checkbox" name="favorites" value="Hono"/>`.
143+
If you have an input field that allows multiple `<input type="file" multiple />` or multiple checkboxes with the same name `<input type="checkbox" name="favorites" value="Hono"/>`.
144144

145145
```ts twoslash
146146
import { Context } from 'hono'

docs/concepts/routers.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ Hono has five routers.
88

99
**RegExpRouter** is the fastest router in the JavaScript world.
1010

11-
Although this is called "RegExp" it is not an Express-like implementation using [path-to-regexp](https://github.com/pillarjs/path-to-regexp).
11+
Although this is called "RegExp", it is not an Express-like implementation using [path-to-regexp](https://github.com/pillarjs/path-to-regexp).
1212
They are using linear loops.
1313
Therefore, regular expression matching will be performed for all routes and the performance will be degraded as you have more routes.
1414

@@ -53,7 +53,7 @@ RegExpRouter is fast, but the route registration phase can be slightly slow.
5353
So, it's not suitable for an environment that initializes with every request.
5454

5555
**LinearRouter** is optimized for "one shot" situations.
56-
Route registration is significantly faster than with RegExpRouter because it adds the route without compiling strings, using a linear approach.
56+
Route registration is significantly faster than RegExpRouter because it adds the route without compiling strings, using a linear approach.
5757

5858
The following is one of the benchmark results, which includes the route registration phase.
5959

docs/concepts/stacks.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
# Hono Stacks
22

33
Hono makes easy things easy and hard things easy.
4-
It is suitable for not just only returning JSON.
5-
But it's also great for building the full-stack application including REST API servers and the client.
4+
It is suitable for not just only returning JSON, but it's also great for building the full-stack application including REST API servers and the client.
65

76
## RPC
87

@@ -94,7 +93,7 @@ export type AppType = typeof route
9493

9594
## Client
9695

97-
Next. The client-side implementation.
96+
Next, The client-side implementation.
9897
Create a client object by passing the `AppType` type to `hc` as generics.
9998
Then, magically, completion works and the endpoint path and request type are suggested.
10099

docs/concepts/web-standard.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Hono uses only **Web Standards** like Fetch.
44
They were originally used in the `fetch` function and consist of basic objects that handle HTTP requests and responses.
55
In addition to `Requests` and `Responses`, there are `URL`, `URLSearchParam`, `Headers` and others.
66

7-
Cloudflare Workers, Deno, and Bun also build upon Web Standards.
7+
Cloudflare Workers, Deno, and Bun also are built upon Web Standards.
88
For example, a server that returns "Hello World" could be written as below. This could run on Cloudflare Workers and Bun.
99

1010
```ts twoslash

docs/getting-started/aws-lambda.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Hono works on AWS Lambda with the Node.js 18+ environment.
99

1010
When creating the application on AWS Lambda,
1111
[CDK](https://docs.aws.amazon.com/cdk/v2/guide/home.html)
12-
is useful to setup the functions such as IAM Role, API Gateway, and others.
12+
is useful to set up the functions such as IAM Role, API Gateway, and others.
1313

1414
Initialize your project with the `cdk` CLI.
1515

docs/getting-started/azure-functions.md

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

33
[Azure Functions](https://azure.microsoft.com/en-us/products/functions) is a serverless platform from Microsoft Azure. You can run your code in response to events, and it automatically manages the underlying compute resources for you.
44

5-
Hono was not designed for Azure Functions at first. But with [Azure Functions Adapter](https://github.com/Marplex/hono-azurefunc-adapter) it can run on it as well.
5+
Hono was not designed for Azure Functions at first, but with [Azure Functions Adapter](https://github.com/Marplex/hono-azurefunc-adapter), it can run on it as well.
66

77
It works with Azure Functions **V4** running on Node.js 18 or above.
88

docs/getting-started/bun.md

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

3-
[Bun](https://bun.com) is another JavaScript runtime. It's not Node.js or Deno. Bun includes a trans compiler, we can write the code with TypeScript.
3+
[Bun](https://bun.com) is another JavaScript runtime. It's not Node.js or Deno. Bun includes a transcompiler, we can write the code with TypeScript.
44
Hono also works on Bun.
55

66
## 1. Install Bun
@@ -90,7 +90,7 @@ export default { // [!code ++]
9090

9191
## Serve static files
9292

93-
To serve static files, use `serveStatic` imported from `hono/bun`.
93+
To serve static files, use `serveStatic` which is imported from `hono/bun`.
9494

9595
```ts
9696
import { serveStatic } from 'hono/bun'

0 commit comments

Comments
 (0)