diff options
author | PhilipWitte <witte2008@gmail.com> | 2015-02-20 08:54:07 -0800 |
---|---|---|
committer | PhilipWitte <witte2008@gmail.com> | 2015-02-20 08:54:07 -0800 |
commit | 73fbcc1f649b21547d368658a3b074da3166cb96 (patch) | |
tree | 25a097bae054eb52785030178f88c152a1ad3d32 /tools/website.tmpl | |
parent | 53c83c4510986308a188abd34f3ec3b0460b30e4 (diff) | |
download | Nim-73fbcc1f649b21547d368658a3b074da3166cb96.tar.gz |
Fixup website support page and other minor touches.
Diffstat (limited to 'tools/website.tmpl')
-rw-r--r-- | tools/website.tmpl | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/tools/website.tmpl b/tools/website.tmpl index ba08c9c4c..bc3ed8e2c 100644 --- a/tools/website.tmpl +++ b/tools/website.tmpl @@ -65,7 +65,7 @@ </div> <div id="slide1"> <div> - <h2>Nim looks like this..</h2> + <h2>Nim is simple..</h2> <pre> <span class="cmt"># compute average line length</span> <span class="kwd">var</span> @@ -81,7 +81,7 @@ echo(<span class="val">"Average line length: "</span>, </pre> </div> <div> - <h2>..and this...</h2> + <h2>..and type safe...</h2> <pre> <span class="cmt"># create and greet someone</span> <span class="kwd">type</span> <span class="def">Person</span> = <span class="kwd">object</span> @@ -92,7 +92,7 @@ echo(<span class="val">"Average line length: "</span>, <span class="tab"> </span>echo <span class="val">"Hi, I'm "</span>, p.name, <span class="val">"."</span> <span class="tab end"> </span>echo <span class="val">"I am "</span>, p.age, <span class="val">" years old."</span> -<span class="kwd">var</span> p = <span class="typ">Person</span>(name:<span class="val">"Jon"</span>, age:<span class="val">18</span>) +<span class="kwd">let</span> p = <span class="typ">Person</span>(name:<span class="val">"Jon"</span>, age:<span class="val">18</span>) p.greet() <span class="cmt"># or greet(p)</span> </pre> </div> @@ -108,7 +108,7 @@ p.greet() <span class="cmt"># or greet(p)</span> <span class="tab end"> </span>header: <span class="val">"<stdio.h>"</span>.} <span class="cmt"># ..and use it...</span> -<span class="kwd">var</span> x: cint +<span class="kwd">var</span> x: <span class="typ">cint</span> stdin.unsafeScanf(<span class="val">"%d"</span>, <span class="kwd">addr</span> x) </pre> <p><span class="desc"><b>Compile and run with:</b><br> $ nim c -r example.nim</span></p> @@ -116,10 +116,10 @@ stdin.unsafeScanf(<span class="val">"%d"</span>, <span class="kwd">addr</span> x <div> <h2>..and DSLs are too...</h2> <pre> -<span class="cmt"># a simple web server</span> -<span class="kwd">import</span> jester, asyncdispatch, htmlgen +<span class="cmt"># a simple html server</span> +<span class="kwd">import</span> + jester, asyncdispatch, htmlgen -<span class="cmt"># using jester commands</span> <span class="kwd">routes</span>: <span class="tab"> </span><span class="kwd">get</span> <span class="val">"/"</span>: <span class="tab end"> <span class="tab end"> </span></span><span class="kwd">resp</span> h1(<span class="val">"Hello world"</span>) @@ -146,7 +146,7 @@ runForever() # end for </div> # end if -# if len(c.ticker) > 0 and currentTab != "support": +# if len(c.ticker) > 0: <h3 class="blue">Latest News</h3> <div id="sidebar-news"> $c.ticker @@ -173,6 +173,7 @@ runForever() <div> <h4>Documentation</h4> <a href="documentation.html">Stable Documentation</a> + <a href="learn.html">Learning Resources</a> <!-- <a href="">Development Documentation</a> --> <a href="https://github.com/Araq/Nimrod">Issues & Requests</a> </div> |