Skip to content

Commit d13200f

Browse files
authored
docs: tidy up runtime landing page (#3172)
1 parent 2ca25d2 commit d13200f

2 files changed

Lines changed: 37 additions & 29 deletions

File tree

js/tabs.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,15 @@ for (const tabGroup of document.querySelectorAll<HTMLElement>(".deno-tabs")) {
7979
const storedTabId = localStorage.getItem(`deno-tab-${groupId}`);
8080
if (storedTabId) {
8181
document.dispatchEvent(new GroupSelectEvent(groupId, storedTabId));
82+
} else if (groupId === "operating-systems") {
83+
const ua = navigator.userAgent;
84+
let detected: string | null = null;
85+
if (/Mac/i.test(ua)) detected = "mac";
86+
else if (/Win/i.test(ua)) detected = "windows";
87+
else if (/Linux/i.test(ua)) detected = "linux";
88+
if (detected) {
89+
document.dispatchEvent(new GroupSelectEvent(groupId, detected));
90+
}
8291
}
8392

8493
const anyTabActive = Array.from(tabs).some((tab) =>

runtime/index.md

Lines changed: 28 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -17,51 +17,49 @@ oldUrl:
1717
`dee-no`) is an
1818
[open source](https://github.com/denoland/deno/blob/main/LICENSE.md) JavaScript,
1919
TypeScript, and WebAssembly runtime with secure defaults and a great developer
20-
experience. It's built on [V8](https://v8.dev/),
21-
[Rust](https://www.rust-lang.org/), and [Tokio](https://tokio.rs/).
20+
experience.
2221

2322
## Why Deno?
2423

25-
- Deno is
26-
**[TypeScript-ready out of the box](/runtime/fundamentals/typescript/).** Zero
27-
config or additional steps necessary.
28-
- Deno is **[secure by default](/runtime/fundamentals/security/).** Where other
29-
runtimes give full access every script they run, Deno allows you to enforce
30-
granular permissions.
31-
- Deno has a **robust built-in toolchain.** Unlike Node or browser JavaScript,
32-
Deno includes a [standard library](/runtime/reference/std/), along with a
33-
first-party [linter/formatter](/runtime/fundamentals/linting_and_formatting/),
34-
[test runner](/runtime/fundamentals/testing/), and more.
35-
- Deno is **fully compatible with [Node and npm](/runtime/fundamentals/node/).**
36-
- Deno is **fast and reliable**.
37-
- **[Deno is open-source](https://github.com/denoland/deno).**
24+
- **Works with your existing [Node.js projects](/runtime/fundamentals/node/).**
25+
Drop Deno into a repo with `package.json` and `node_modules` and it just runs;
26+
mix `npm:` imports with native ES modules as you migrate.
27+
- **Modern module system.** ES modules with URL imports, [JSR](https://jsr.io)
28+
for typed packages, and [workspaces](/runtime/fundamentals/workspaces/).
29+
- **[TypeScript-first](/runtime/fundamentals/typescript/).** Run `.ts` files
30+
directly. No `tsc`, no build step, no config.
31+
- **[Secure by default](/runtime/fundamentals/security/).** Code runs in a
32+
sandbox with no file, network, or environment access until you grant it.
33+
- **A full toolchain, no plumbing.** Built-in
34+
[formatter](/runtime/fundamentals/linting_and_formatting/),
35+
[linter](/runtime/fundamentals/linting_and_formatting/),
36+
[test runner](/runtime/fundamentals/testing/), benchmarking, and
37+
[a lot more](/runtime/reference/cli/). No `devDependencies` to wire up.
3838

3939
## Quick install
4040

4141
Install the Deno runtime on your system using one of the terminal commands
4242
below:
4343

4444
<deno-tabs group-id="operating-systems">
45-
<deno-tab value="mac" label="macOS" default>
45+
<deno-tab value="linux" label="Linux">
4646

4747
```sh
4848
curl -fsSL https://deno.land/install.sh | sh
4949
```
5050

5151
</deno-tab>
52-
<deno-tab value="windows" label="Windows">
53-
54-
In Windows PowerShell:
52+
<deno-tab value="mac" label="macOS" default>
5553

56-
```powershell
57-
irm https://deno.land/install.ps1 | iex
54+
```sh
55+
curl -fsSL https://deno.land/install.sh | sh
5856
```
5957

6058
</deno-tab>
61-
<deno-tab value="linux" label="Linux">
59+
<deno-tab value="windows" label="Windows">
6260

63-
```sh
64-
curl -fsSL https://deno.land/install.sh | sh
61+
```shell title="pwsh"
62+
irm https://deno.land/install.ps1 | iex
6563
```
6664

6765
</deno-tab>
@@ -75,12 +73,13 @@ system path. You can verify the installation by running:
7573
deno --version
7674
```
7775

78-
## First steps
76+
## Next steps
7977

80-
Deno can run JavaScript and [TypeScript](https://www.typescriptlang.org/) with
81-
no additional tools or configuration required, all in a secure,
82-
batteries-included runtime.
78+
With Deno installed, dive into the rest of the Getting Started guide:
8379

8480
- [Making a Deno project](/runtime/getting_started/first_project/)
8581
- [Setting up your environment](/runtime/getting_started/setup_your_environment/)
86-
- [Using the CLI](/runtime/getting_started/command_line_interface)
82+
- [Using the CLI](/runtime/getting_started/command_line_interface/)
83+
84+
For more installation options (package managers, Docker, building from source),
85+
see the full [installation guide](/runtime/getting_started/installation/).

0 commit comments

Comments
 (0)