2 Mar 2018
5 min read
If you're new to FP or you haven't tackled Brian's course, then I highly recommend that you do that first (I certainly did, and it helped me a lot). Then, once you understand the basic abstractions, come back and I'll show you them in PureScript. I've done my best to explain the concepts, but Brian is a master at teaching them. Also, these tutorials are not a replacement for a good old fashioned PureScript primer. So take the time to learn a little PureScript syntax before diving head first into these tutorials.
Each tutorial has been placed in a separate folder named 'tut##', where ## is a number (e.g., 'tut01') that corresponds to video## from Brian's course. I have set up the folders so that you can run the PureScript code samples for the first time with
bower update && pulp run, then
pulp run from then on (explained below). You will also find the accompanying tutorial markdown (e.g., tut01/README.md) which illustrates the abstraction from Brian's corresponding video (e.g. video1) and how to implement it in PureScript.
You can skip this section if you've already installed and are using PureScript on your computer.
Seriously? Don't you have 10-minutes to review the career changing Getting Started with PureScript? Well then I wash my hands or (as Japanese would have it, my feet) of all responsibility for the results. All kidding aside:
npm install -g purescript pulp bower
Assuming you've installed PureScript, Pulp, and Bower, then it doesn't get any easier than this to start your adventure in functional programming with PureScript:
mkdir purescript-hello cd purescript-hello pulp init pulp run
Pulp is an excellent build tool with plenty of helper options; such as watching for source file updates and re-compiling them automatically. As you add more library dependencies to your program, you can install them with
bower install purescript-lists --save)
I'll add additional links as I write the tutorials. But If you would like to look ahead, then the majority of the code samples from Brian's videos are available on Github. But I may amend them as I write the accompanying tutorial markdown.
Ground Floor, Verse Building, 18 Brunswick Place, London, N1 6DZ
108 E 16th Street, New York, NY 10003
Join over 111,000 others and get access to exclusive content, job opportunities and more!