Skip to content

Commit

Permalink
deno fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
John Donmoyer committed Sep 1, 2023
1 parent 65ee5cd commit 234c1c2
Show file tree
Hide file tree
Showing 12 changed files with 34 additions and 34 deletions.
12 changes: 8 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Website

This website is built using [Docusaurus 2](https://docusaurus.io/), a modern static website generator.
This website is built using [Docusaurus 2](https://docusaurus.io/), a modern
static website generator.

### Installation

Expand All @@ -14,15 +15,17 @@ $ yarn
$ yarn start
```

This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.
This command starts a local development server and opens up a browser window.
Most changes are reflected live without having to restart the server.

### Build

```
$ yarn build
```

This command generates static content into the `build` directory and can be served using any static contents hosting service.
This command generates static content into the `build` directory and can be
served using any static contents hosting service.

### Deployment

Expand All @@ -38,4 +41,5 @@ Not using SSH:
$ GIT_USER=<Your GitHub username> yarn deploy
```

If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch.
If you are using GitHub pages for hosting, this command is a convenient way to
build the website and push to the `gh-pages` branch.
2 changes: 1 addition & 1 deletion babel.config.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module.exports = {
presets: [require.resolve('@docusaurus/core/lib/babel/preset')],
presets: [require.resolve("@docusaurus/core/lib/babel/preset")],
};
13 changes: 5 additions & 8 deletions deploy/api/runtime-fetch.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,16 @@ allows you to make outbound HTTP requests in Deno Deploy. It is a web standard
and has the following interfaces:

- `fetch()` - The method that allows you to make outbound HTTP requests
- [`Request`](./runtime-request) - represents a request resource of
fetch()
- [`Response`](./runtime-response) - represents a response resource of
fetch()
- [`Request`](./runtime-request) - represents a request resource of fetch()
- [`Response`](./runtime-response) - represents a response resource of fetch()
- [`Headers`](./runtime-headers) - represents HTTP Headers of requests and
responses.

This page shows usage for the fetch() method. You can click above on the other
interfaces to learn more about them.

Fetch also supports fetching from file URLs to retrieve static files. For more
info on static files, see the
[filesystem API documentation](./runtime-fs).
info on static files, see the [filesystem API documentation](./runtime-fs).

## `fetch()`

Expand All @@ -33,8 +30,8 @@ function fetch(

#### Parameters

| name | type | optional | description |
| -------- | ------------------------------------------------------------------- | -------- | ------------------------------------------------------------------ |
| name | type | optional | description |
| -------- | ------------------------------------------------------------- | -------- | ------------------------------------------------------------------ |
| resource | [`Request`](./runtime-request) <br/> [`USVString`][usvstring] | `false` | The resource can either be a request object or a URL string. |
| init | [`RequestInit`](./runtime-request#requestinit) | `true` | The init object lets you apply optional parameters to the request. |

Expand Down
7 changes: 3 additions & 4 deletions deploy/api/runtime-fs.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,9 @@ serve(handler);

> Note: to use this feature, you must link a GitHub repository to your project.
Deno Deploy supports the `Deno.readFile`
API to read static assets from the file system. This is useful for serving
static assets such as images, stylesheets, and JavaScript files. This guide
demonstrates how to use this feature.
Deno Deploy supports the `Deno.readFile` API to read static assets from the file
system. This is useful for serving static assets such as images, stylesheets,
and JavaScript files. This guide demonstrates how to use this feature.

Imagine the following file structure on a GitHub repository:

Expand Down
2 changes: 1 addition & 1 deletion deploy/api/runtime-request.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ The return type is a `Request` instance.
| [`body`][body] | [`ReadableStream`][readablestream] | The getter exposes a `ReadableStream` of the body contents. |
| [`bodyUsed`][bodyused] | `boolean` | Indicates whether the body content is read. |
| [`url`][url] | `USVString` | The URL of the request. |
| [`headers`][headers] | [`Headers`](runtime-headers) | The headers associated with the request. |
| [`headers`][headers] | [`Headers`](runtime-headers) | The headers associated with the request. |
| [`integrity`][integrity] | `string` | The crypotographic hash of the request's body. |
| [`method`][method] | `string` | The request's method (`POST`, `GET`, etc). |
| [`mode`][mode] | `string` | Indicates the mode of the request (e.g. `cors` ). |
Expand Down
4 changes: 2 additions & 2 deletions deploy/manual/pricing-and-limits.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ warning will be logged to the deployment's logs.
| BroadcastChannel | 64KB/sec send rate per isolate, no limit on receive | The same as Free |

> Isolate: an instance of your deployment running in any one of the
> [available regions](regions). Isolates are created and destroyed on
> demand based on traffic to your deployment.
> [available regions](regions). Isolates are created and destroyed on demand
> based on traffic to your deployment.
If you have a use case that exceeds any of these limits,
[please reach out](mailto:deploy@deno.com).
Expand Down
4 changes: 2 additions & 2 deletions runtime/manual/basics/debugging_your_code.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ execution on the first line of code.
## Chrome Devtools

Let's try debugging a program using Chrome Devtools. For this, we'll use
[file_server.ts](https://deno.land/std/http/file_server.ts) from
`std`, a static file server.
[file_server.ts](https://deno.land/std/http/file_server.ts) from `std`, a static
file server.

Use the `--inspect-brk` flag to break execution on the first line:

Expand Down
4 changes: 2 additions & 2 deletions runtime/manual/basics/env_variables.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,5 @@ console.log(password);
## `std/flags`

The Deno standard library has a
[`std/flags` module](https://deno.land/std/flags/mod.ts) for
parsing command line arguments.
[`std/flags` module](https://deno.land/std/flags/mod.ts) for parsing command
line arguments.
4 changes: 2 additions & 2 deletions runtime/manual/basics/standard_library.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ Standard library is available at: https://deno.land/std

Standard library is not yet stable and therefore it is versioned differently
than Deno. For latest release consult https://deno.land/std or
https://deno.land/std/version.ts. The standard library is released
each time Deno is released.
https://deno.land/std/version.ts. The standard library is released each time
Deno is released.

We strongly suggest to always use imports with pinned version of standard
library to avoid unintended changes. For example, rather than linking to the
Expand Down
7 changes: 3 additions & 4 deletions runtime/manual/getting_started/first_steps.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ deno run first_steps.ts
```

Deno also has the ability to execute scripts from URLs. Deno
[hosts a library](https://deno.land/std/examples) of example code,
one of which is a `Hello World` program. To run that hosted code, do:
[hosts a library](https://deno.land/std/examples) of example code, one of which
is a `Hello World` program. To run that hosted code, do:

```shell
deno run https://deno.land/std/examples/welcome.ts
Expand Down Expand Up @@ -72,8 +72,7 @@ Try it out:
deno run first_steps.ts
```

Or, try this script hosted at
`https://deno.land/std/examples/curl.ts`:
Or, try this script hosted at `https://deno.land/std/examples/curl.ts`:

```shell
deno run https://deno.land/std/examples/curl.ts https://deno.com
Expand Down
5 changes: 3 additions & 2 deletions runtime/manual/tools/script_installer.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,9 @@ deno install --allow-net --allow-read https://deno.land/std/http/file_server.ts
The above command creates an executable called `file_server` that runs with
network and read permissions and binds to port 8080.

For good practice, use the [`import.meta.main`](../../tutorials/module_metadata.md)
idiom to specify the entry point in an executable script.
For good practice, use the
[`import.meta.main`](../../tutorials/module_metadata.md) idiom to specify the
entry point in an executable script.

Example:

Expand Down
4 changes: 2 additions & 2 deletions runtime/tutorials/file_server.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ async function handleHttp(conn: Deno.Conn) {
## Using the `std/http` file server

The Deno standard library provides you with a
[file server](https://deno.land/std/http/file_server.ts) so that
you don't have to write your own.
[file server](https://deno.land/std/http/file_server.ts) so that you don't have
to write your own.

To use it, first install the remote script to your local file system. This will
install the script to the Deno installation root's bin directory, e.g.
Expand Down

0 comments on commit 234c1c2

Please sign in to comment.