Skip to content

Commit 12dee9b

Browse files
authored
Merge pull request #103 from purescript/phil/updates
Various updates
2 parents 7b5d0d4 + dd43b96 commit 12dee9b

File tree

8 files changed

+51
-89
lines changed

8 files changed

+51
-89
lines changed

community/index.html

+1-10
Original file line numberDiff line numberDiff line change
@@ -41,17 +41,8 @@ <h2>Online</h2>
4141
<li><a href="https://groups.google.com/group/purescript">Mailing List</a>: A Google Groups mailing list for discussing anything and everything related to PureScript.</li>
4242
<li><a href="http://www.reddit.com/r/purescript">Reddit (/r/purescript)</a>: A subreddit for community-submitted articles and links.</li>
4343
<li><a href="https://twitter.com/purescript">Twitter (@purescript)</a>: Follow along for news from the PureScript community.</li>
44-
<li><a href="https://github.com/purescript/purescript/wiki">GitHub Wiki</a>: The wiki contains community-written articles about the language and its tools.</li>
4544
<li><a href="http://stackoverflow.com/questions/tagged/purescript">StackOverflow</a>: Browse questions tagged with PureScript or ask one of your own.</li>
46-
<li><a href="http://www.meetup.com/Bay-Area-PureScript-Meetup/">Remote PureScript Meetups</a> (Talks and Hacks): Organised out of the Bay Area PureScript Meetup account, these are starting tentatively on the second Saturday of the month.</li>
47-
</ul>
48-
</section>
49-
50-
<section>
51-
<h2>In Real Life</h2>
52-
<ul>
53-
<li><a href="http://www.meetup.com/Bay-Area-PureScript-Meetup/">Bay Area (California) PureScript Meetup</a></li>
54-
<li><a href="http://www.meetup.com/lambdaconf/events/227877444/">PureScript Conf 2016</a>: A side-event co-located with <a href="http://lambdaconf.us/">LambdaConf 2016</a> this year in Boulder, Colorado.</li>
45+
<li><a href="https://github.com/purescript/documentation/blob/master/ecosystem/PureScript-Meetups.md">Remote PureScript Meetups</a>: Weekend online meetups.</li>
5546
</ul>
5647
</section>
5748

download/index.html

+3-3
Original file line numberDiff line numberDiff line change
@@ -84,9 +84,9 @@ <h2>Stack</h2>
8484

8585
<p>If you don't have Stack installed, there are install instructions <a href="https://github.com/commercialhaskell/stack/blob/master/doc/install_and_upgrade.md">here</a>.</p>
8686

87-
<p>You can also install a specific version by specifying it in the <code>stack unpack</code> step. For example, to install 0.8.5, use:</p>
87+
<p>You can also install a specific version by specifying it in the <code>stack unpack</code> step. For example, to install 0.10.3, use:</p>
8888
<pre>
89-
stack unpack purescript-0.8.5</pre>
89+
stack unpack purescript-0.10.3</pre>
9090
</section>
9191

9292
<section>
@@ -101,7 +101,7 @@ <h2>Tools</h2>
101101

102102
<p>Alternatives such as <code>gulp-purescript</code> exist for more advanced configurations.</p>
103103

104-
<p>The <a href="https://github.com/purescript/purescript/wiki/Editor-and-tool-support">PureScript wiki</a> has a list of available editor plugins.</p>
104+
<p>The PureScript <a href="https://github.com/purescript/documentation/blob/master/ecosystem/Editor-and-tool-support.md">documentation repository</a> has a list of available editor plugins.</p>
105105

106106
</section>
107107

generator/community/index.html

+1-10
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,7 @@ <h2>Online</h2>
55
<li><a href="https://groups.google.com/group/purescript">Mailing List</a>: A Google Groups mailing list for discussing anything and everything related to PureScript.</li>
66
<li><a href="http://www.reddit.com/r/purescript">Reddit (/r/purescript)</a>: A subreddit for community-submitted articles and links.</li>
77
<li><a href="https://twitter.com/purescript">Twitter (@purescript)</a>: Follow along for news from the PureScript community.</li>
8-
<li><a href="https://github.com/purescript/purescript/wiki">GitHub Wiki</a>: The wiki contains community-written articles about the language and its tools.</li>
98
<li><a href="http://stackoverflow.com/questions/tagged/purescript">StackOverflow</a>: Browse questions tagged with PureScript or ask one of your own.</li>
10-
<li><a href="http://www.meetup.com/Bay-Area-PureScript-Meetup/">Remote PureScript Meetups</a> (Talks and Hacks): Organised out of the Bay Area PureScript Meetup account, these are starting tentatively on the second Saturday of the month.</li>
11-
</ul>
12-
</section>
13-
14-
<section>
15-
<h2>In Real Life</h2>
16-
<ul>
17-
<li><a href="http://www.meetup.com/Bay-Area-PureScript-Meetup/">Bay Area (California) PureScript Meetup</a></li>
18-
<li><a href="http://www.meetup.com/lambdaconf/events/227877444/">PureScript Conf 2016</a>: A side-event co-located with <a href="http://lambdaconf.us/">LambdaConf 2016</a> this year in Boulder, Colorado.</li>
9+
<li><a href="https://github.com/purescript/documentation/blob/master/ecosystem/PureScript-Meetups.md">Remote PureScript Meetups</a>: Weekend online meetups.</li>
1910
</ul>
2011
</section>

generator/download/index.html

+3-3
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,9 @@ <h2>Stack</h2>
4848

4949
<p>If you don't have Stack installed, there are install instructions <a href="https://github.com/commercialhaskell/stack/blob/master/doc/install_and_upgrade.md">here</a>.</p>
5050

51-
<p>You can also install a specific version by specifying it in the <code>stack unpack</code> step. For example, to install 0.8.5, use:</p>
51+
<p>You can also install a specific version by specifying it in the <code>stack unpack</code> step. For example, to install 0.10.3, use:</p>
5252
<pre>
53-
stack unpack purescript-0.8.5</pre>
53+
stack unpack purescript-0.10.3</pre>
5454
</section>
5555

5656
<section>
@@ -65,6 +65,6 @@ <h2>Tools</h2>
6565

6666
<p>Alternatives such as <code>gulp-purescript</code> exist for more advanced configurations.</p>
6767

68-
<p>The <a href="https://github.com/purescript/purescript/wiki/Editor-and-tool-support">PureScript wiki</a> has a list of available editor plugins.</p>
68+
<p>The PureScript <a href="https://github.com/purescript/documentation/blob/master/ecosystem/Editor-and-tool-support.md">documentation repository</a> has a list of available editor plugins.</p>
6969

7070
</section>

generator/index.html

+18-14
Original file line numberDiff line numberDiff line change
@@ -10,48 +10,52 @@ <h3>Examples</h3>
1010
<div class="current example">
1111
<h4>Modifying the DOM</h4>
1212
<p>PureScript’s expressive type system and lightweight syntax make it simple to define <a href="https://leanpub.com/purescript/read#leanpub-auto-domain-specific-languages">domain-specific languages</a>, which can be used to solve problems like templating the DOM. Bindings also exist for libraries such as React and Virtual DOM.</p>
13+
<p>
14+
You can <a href="http://try.purescript.org/?gist=297b324cca7fdd6a802a7365c2c5ea62&backend=flare">try this example</a> online.
15+
</p>
1316
<pre>
1417
<span class="kr">import</span> <span class="nn">Flare</span>
1518
<span class="kr">import</span> <span class="nn">Flare.Smolder</span>
1619
&nbsp;
17-
<span class="nf">ui</span> :: UI _ H.Markup
1820
<span class="nf">ui</span> = greet <span class="kt">&lt;$&gt;</span> string <span class="s">"Name"</span> <span class="s">"World"</span>
1921
where
2022
<span class="nf">greet</span> name = h1 <span class="kt">$</span> text <span class="kt">$</span> <span class="s">"Hello, "</span> <span class="kt">&lt;&gt;</span> name <span class="kt">&lt;&gt;</span> <span class="s">"!"</span></pre>
2123
</div>
2224
<div class="example">
2325
<h4>HTML5 Canvas</h4>
24-
<p>Higher-order functions allow the developer to write fluent, expressive code. Here, higher-order functions are being used to capture some common patterns when <a href="https://leanpub.com/purescript/read#leanpub-auto-canvas-graphics">working with HTML5 canvas</a>, such as closing and filling paths.</p>
26+
<p>Higher-order functions allow the developer to write fluent, expressive code. Here, the higher-order function <code>thrice</code> is being used to simplify some code while <a href="https://leanpub.com/purescript/read#leanpub-auto-canvas-graphics">working with the canvas</a>.</p>
27+
<p>
28+
You can <a href="http://try.purescript.org/?gist=1c497b0533c1e1e4c21ebdbbd4195a79&backend=flare">try this example</a> online.
29+
</p>
2530
<pre>
26-
<span class="kr">import</span> <span class="nn">Control.Apply</span>
27-
<span class="kr">import</span> <span class="nn">Graphics.Canvas.Free</span>
31+
<span class="kr">import</span> <span class="nn">import Flare</span>
32+
<span class="kr">import</span> <span class="nn">import Flare.Drawing</span>
2833

29-
<span class="nf">scene</span> =
30-
filled $ closed <span class="kr">do</span>
31-
moveTo <span class="mi">0</span> <span class="mi">0</span>
32-
lineTo <span class="mi">50</span> <span class="mi">0</span>
33-
lineTo <span class="mi">25</span> <span class="mi">50</span>
34-
<span class="kr">where</span>
35-
<span class="nf">closed</span> path = beginPath *&gt; path &lt;* closePath
36-
<span class="nf">filled</span> shape = shape &lt;* fill</pre>
34+
<span class="nf">thrice</span> f x = f (f (f x))
35+
36+
<span class="nf">scene</span> = thrice subdivide
37+
$ outlined (outlineColor black)
38+
$ circle <span class="mi">0.0</span> <span class="mi">0.0</span> <span class="mi">1.0</span></pre>
3739
</div>
3840
<div class="example">
3941
<h4>Callback Hell</h4>
4042
<p>The problem of <a href="https://leanpub.com/purescript/read#leanpub-auto-callback-hell">callback hell</a> can be solved by using PureScript’s type system to capture complex control flow as functions in a safe way. Here, the continuation monad is used to hide the boilerplate code associated with handling callbacks.</p>
4143
<pre>
4244
<span class="kr">import</span> <span class="nn">Control.Monad.Aff</span>
43-
<span class="kr">import</span> <span class="nn">Control.Monad.Aff.Par</span>
4445

4546
<span class="kr">data</span> <span class="kt">Model</span> = <span class="kt">Model</span> (<span class="kt">List Product</span>)
4647

4748
<span class="nf">loadModel</span> = <span class="kr">do</span>
4849
popular <- get <span class="s">"/products/popular"</span>
49-
products <- runPar $ for_ popular \product -> <span class="kt">Par</span> (get product.uri)
50+
products <- parTraverse (\product -> get product.uri) popular
5051
pure (<span class="kt">Model</span> products)</pre>
5152
</div>
5253
<div class="example">
5354
<h4>Generative Testing</h4>
5455
<p>PureScript provides a form of ad-hoc polymorphism in the form of type classes, inspired by Haskell. Type classes are used in the QuickCheck and StrongCheck libraries to support <a href="https://leanpub.com/purescript/read#leanpub-auto-generative-testing">generative testing</a>, which separates test definitions from the generation of test cases.</p>
56+
<p>
57+
You can <a href="http://try.purescript.org/?gist=b291f5ce33b92885b8be069e6a6bddb8&backend=core">try this example</a> online.
58+
</p>
5559
<pre>
5660
<span class="kr">import</span> <span class="nn">Test.QuickCheck</span>
5761

generator/learn/index.html

+3-17
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,10 @@ <h3>Pursuit</h3>
3131
</div>
3232
</li>
3333
<li>
34-
<h3>PureScript Wiki</h3>
35-
<p>The Wiki contains community-written articles about the language and its tools.</p>
34+
<h3>Documentation Repo</h3>
35+
<p>This repository contains curated documentation about various aspects of the language.</p>
3636
<div class="link">
37-
<a href="https://github.com/purescript/purescript/wiki">View</a>
37+
<a href="https://github.com/purescript/documentation">View</a>
3838
</div>
3939
</li>
4040
<li>
@@ -104,20 +104,6 @@ <h3>The Partial type class</h3>
104104
</ul>
105105
</section>
106106

107-
<section>
108-
<h2 id="articles">Articles by Users</h2>
109-
110-
<ul>
111-
<li><a href="http://blog.functorial.com/posts/2015-11-20-Thermite.html">Building a Task List Application with Thermite</a> <small>(at <a href="http://blog.functorial.com">blog.functorial.com</a>)</small></li>
112-
<li><a href="http://www.parsonsmatt.org/programming/2015/10/22/purescript_router.html">Using purescript-routing with purescript-halogen</a> <small>(at <a href="http://parsonsmatt.org">parsonsmatt.org</a>)</small></li>
113-
<li><a href="http://www.parsonsmatt.org/programming/2015/10/05/elm_vs_purescript_ii.html">The Elm Architecture in PureScript</a> <small>(at <a href="http://parsonsmatt.org">parsonsmatt.org</a>)</small></li>
114-
</ul>
115-
116-
<div>Please contribute your own content by <a href="https://github.com/purescript/purescript.github.io">sending a pull request</a>.</div>
117-
118-
</section>
119-
120-
121107
<section>
122108

123109
<h2 id="talks">Talks and Slides</h2>

index.html

+19-15
Original file line numberDiff line numberDiff line change
@@ -46,48 +46,52 @@ <h3>Examples</h3>
4646
<div class="current example">
4747
<h4>Modifying the DOM</h4>
4848
<p>PureScript’s expressive type system and lightweight syntax make it simple to define <a href="https://leanpub.com/purescript/read#leanpub-auto-domain-specific-languages">domain-specific languages</a>, which can be used to solve problems like templating the DOM. Bindings also exist for libraries such as React and Virtual DOM.</p>
49+
<p>
50+
You can <a href="http://try.purescript.org/?gist=297b324cca7fdd6a802a7365c2c5ea62&backend=flare">try this example</a> online.
51+
</p>
4952
<pre>
5053
<span class="kr">import</span> <span class="nn">Flare</span>
5154
<span class="kr">import</span> <span class="nn">Flare.Smolder</span>
5255
&nbsp;
53-
<span class="nf">ui</span> :: UI _ H.Markup
5456
<span class="nf">ui</span> = greet <span class="kt">&lt;$&gt;</span> string <span class="s">"Name"</span> <span class="s">"World"</span>
5557
where
5658
<span class="nf">greet</span> name = h1 <span class="kt">$</span> text <span class="kt">$</span> <span class="s">"Hello, "</span> <span class="kt">&lt;&gt;</span> name <span class="kt">&lt;&gt;</span> <span class="s">"!"</span></pre>
5759
</div>
5860
<div class="example">
5961
<h4>HTML5 Canvas</h4>
60-
<p>Higher-order functions allow the developer to write fluent, expressive code. Here, higher-order functions are being used to capture some common patterns when <a href="https://leanpub.com/purescript/read#leanpub-auto-canvas-graphics">working with HTML5 canvas</a>, such as closing and filling paths.</p>
62+
<p>Higher-order functions allow the developer to write fluent, expressive code. Here, the higher-order function <code>thrice</code> is being used to simplify some code while <a href="https://leanpub.com/purescript/read#leanpub-auto-canvas-graphics">working with the canvas</a>.</p>
63+
<p>
64+
You can <a href="http://try.purescript.org/?gist=1c497b0533c1e1e4c21ebdbbd4195a79&backend=flare">try this example</a> online.
65+
</p>
6166
<pre>
62-
<span class="kr">import</span> <span class="nn">Control.Apply</span>
63-
<span class="kr">import</span> <span class="nn">Graphics.Canvas.Free</span>
64-
65-
<span class="nf">scene</span> =
66-
filled $ closed <span class="kr">do</span>
67-
moveTo <span class="mi">0</span> <span class="mi">0</span>
68-
lineTo <span class="mi">50</span> <span class="mi">0</span>
69-
lineTo <span class="mi">25</span> <span class="mi">50</span>
70-
<span class="kr">where</span>
71-
<span class="nf">closed</span> path = beginPath *&gt; path &lt;* closePath
72-
<span class="nf">filled</span> shape = shape &lt;* fill</pre>
67+
<span class="kr">import</span> <span class="nn">import Flare</span>
68+
<span class="kr">import</span> <span class="nn">import Flare.Drawing</span>
69+
70+
<span class="nf">thrice</span> f x = f (f (f x))
71+
72+
<span class="nf">scene</span> = thrice subdivide
73+
$ outlined (outlineColor black)
74+
$ circle <span class="mi">0.0</span> <span class="mi">0.0</span> <span class="mi">1.0</span></pre>
7375
</div>
7476
<div class="example">
7577
<h4>Callback Hell</h4>
7678
<p>The problem of <a href="https://leanpub.com/purescript/read#leanpub-auto-callback-hell">callback hell</a> can be solved by using PureScript’s type system to capture complex control flow as functions in a safe way. Here, the continuation monad is used to hide the boilerplate code associated with handling callbacks.</p>
7779
<pre>
7880
<span class="kr">import</span> <span class="nn">Control.Monad.Aff</span>
79-
<span class="kr">import</span> <span class="nn">Control.Monad.Aff.Par</span>
8081

8182
<span class="kr">data</span> <span class="kt">Model</span> = <span class="kt">Model</span> (<span class="kt">List Product</span>)
8283

8384
<span class="nf">loadModel</span> = <span class="kr">do</span>
8485
popular <- get <span class="s">"/products/popular"</span>
85-
products <- runPar $ for_ popular \product -> <span class="kt">Par</span> (get product.uri)
86+
products <- parTraverse (\product -> get product.uri) popular
8687
pure (<span class="kt">Model</span> products)</pre>
8788
</div>
8889
<div class="example">
8990
<h4>Generative Testing</h4>
9091
<p>PureScript provides a form of ad-hoc polymorphism in the form of type classes, inspired by Haskell. Type classes are used in the QuickCheck and StrongCheck libraries to support <a href="https://leanpub.com/purescript/read#leanpub-auto-generative-testing">generative testing</a>, which separates test definitions from the generation of test cases.</p>
92+
<p>
93+
You can <a href="http://try.purescript.org/?gist=b291f5ce33b92885b8be069e6a6bddb8&backend=core">try this example</a> online.
94+
</p>
9195
<pre>
9296
<span class="kr">import</span> <span class="nn">Test.QuickCheck</span>
9397

learn/index.html

+3-17
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,10 @@ <h3>Pursuit</h3>
6767
</div>
6868
</li>
6969
<li>
70-
<h3>PureScript Wiki</h3>
71-
<p>The Wiki contains community-written articles about the language and its tools.</p>
70+
<h3>Documentation Repo</h3>
71+
<p>This repository contains curated documentation about various aspects of the language.</p>
7272
<div class="link">
73-
<a href="https://github.com/purescript/purescript/wiki">View</a>
73+
<a href="https://github.com/purescript/documentation">View</a>
7474
</div>
7575
</li>
7676
<li>
@@ -140,20 +140,6 @@ <h3>The Partial type class</h3>
140140
</ul>
141141
</section>
142142

143-
<section>
144-
<h2 id="articles">Articles by Users</h2>
145-
146-
<ul>
147-
<li><a href="http://blog.functorial.com/posts/2015-11-20-Thermite.html">Building a Task List Application with Thermite</a> <small>(at <a href="http://blog.functorial.com">blog.functorial.com</a>)</small></li>
148-
<li><a href="http://www.parsonsmatt.org/programming/2015/10/22/purescript_router.html">Using purescript-routing with purescript-halogen</a> <small>(at <a href="http://parsonsmatt.org">parsonsmatt.org</a>)</small></li>
149-
<li><a href="http://www.parsonsmatt.org/programming/2015/10/05/elm_vs_purescript_ii.html">The Elm Architecture in PureScript</a> <small>(at <a href="http://parsonsmatt.org">parsonsmatt.org</a>)</small></li>
150-
</ul>
151-
152-
<div>Please contribute your own content by <a href="https://github.com/purescript/purescript.github.io">sending a pull request</a>.</div>
153-
154-
</section>
155-
156-
157143
<section>
158144

159145
<h2 id="talks">Talks and Slides</h2>

0 commit comments

Comments
 (0)