summaryrefslogtreecommitdiff
path: root/website/index.html
blob: ffd83a253d1b24e0594b41e94a3bb68ad4428f9c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
<!-- Copyright 2018-2019 the Deno authors. All rights reserved. MIT license. -->
<!DOCTYPE html>
<html>
  <head>
    <title>Deno</title>
    <link rel="stylesheet" href="style.css" />
    <meta content="width=device-width, initial-scale=1.0" name="viewport" />
  </head>
  <body>
    <main>
      <header>
        <a href="https://github.com/denolib/animated-deno-logo/"
          ><img id="logo" src="deno_logo_2.gif" width="150"
        /></a>
        <!-- Logo by hashrock -->
        <div>
          <h1>Deno</h1>
          A new way to JavaScript
        </div>
      </header>

      <table>
        <tr>
          <th></th>
          <th>Linux &amp; Mac</th>
          <th>Windows</th>
        </tr>
        <tr>
          <th><a href="https://github.com/denoland/deno">deno</a></th>
          <td>
            <a class="badge" href="https://travis-ci.com/denoland/deno">
              <img
                src="https://travis-ci.com/denoland/deno.svg?branch=master"
              />
            </a>
          </td>
          <td>
            <a class="badge" href="https://ci.appveyor.com/project/deno/deno">
              <img
                src="https://ci.appveyor.com/api/projects/status/yel7wtcqwoy0to8x/branch/master?svg=true"
              />
            </a>
          </td>
        </tr>
        <tr>
          <th><a href="https://github.com/denoland/deno_std">deno_std</a></th>
          <td colspan="2">
            <a
              class="badge"
              href="https://dev.azure.com/denoland/deno_std/_build?definitionId=2"
            >
              <img
                src="https://dev.azure.com/denoland/deno_std/_apis/build/status/denoland.deno_std?branchName=master"
              />
            </a>
          </td>
        </tr>
        <tr>
          <th>
            <a href="https://github.com/denoland/deno_install">deno_install</a>
          </th>
          <td>
            <a class="badge" href="https://travis-ci.com/denoland/deno_install">
              <img
                src="https://travis-ci.com/denoland/deno_install.svg?branch=master"
              />
            </a>
          </td>
          <td>
            <a
              class="badge"
              href="https://ci.appveyor.com/project/deno/deno-install"
            >
              <img
                src="https://ci.appveyor.com/api/projects/status/gtekeaf7r60xa896?branch=master&svg=true"
              />
            </a>
          </td>
        </tr>
        <tr>
          <th><a href="https://github.com/denoland/registry">registry</a></th>
        </tr>
      </table>

      <h2 id="install">Install <a href="#install">#</a></h2>

      <p>Mac or Linux</p>
      <pre>curl -fL <a
href="https://github.com/denoland/deno_install/blob/master/install.sh">https://deno.land/x/install/install.sh</a> | sh</pre>
      <p>Windows (PowerShell)</p>
      <pre>iex (iwr <a
href="https://github.com/denoland/deno_install/blob/master/install.ps1">https://deno.land/x/install/install.ps1</a>)</pre>

      <h2 id="example">Example <a href="#example">#</a></h2>

      <p>Try running a simple program:</p>
      <pre>deno https://deno.land/welcome.js</pre>

      <p>Or a more complex one:</p>

      <pre>
import { serve } from "<a
href="https://github.com/denoland/deno_std/blob/master/http/server.ts">https://deno.land/x/http/server.ts</a>";
const s = serve("0.0.0.0:8000");

async function main() {
  for await (const req of s) {
    req.respond({ body: new TextEncoder().encode("Hello World\n") });
  }
}

main(); </pre>

      <h2 id="dig-in">Dig in... <a href="#dig-in">#</a></h2>

      <p>
        <b><a href="manual.html">Manual</a></b>
      </p>

      <p><a href="https://deno.land/typedoc">API Reference</a></p>

      <p><a href="style_guide.html">Style Guide</a></p>

      <p><a href="https://deno.land/x/">Module repository</a></p>

      <p>
        <a href="https://github.com/denoland/deno/blob/master/Releases.md"
          >Release notes</a
        >
      </p>

      <p><a href="https://gitter.im/denolife/Lobby">Community chat room</a></p>

      <p><a href="benchmarks.html">Benchmarks</a></p>

      <p>
        <a href="https://github.com/denolib/awesome-deno"
          >A curated list of awesome Deno things</a
        >
      </p>
    </main>
  </body>
</html>