Giter Site home page Giter Site logo

joshburgess / purescript-halogen-realworld Goto Github PK

View Code? Open in Web Editor NEW

This project forked from thomashoneyman/purescript-halogen-realworld

1.0 2.0 0.0 672 KB

Exemplary real world application built with PureScript + Halogen

Home Page: https://thomashoneyman.com/guides/real-world-halogen

License: MIT License

PureScript 97.63% JavaScript 0.85% HTML 0.36% Dhall 1.16%

purescript-halogen-realworld's Introduction

Real World Halogen

RealWorld Frontend Maintainer: thomashoneyman

PureScript is a delightful purely-functional language that offers powerful, pragmatic tools to manage complexity and help you design, build, and refactor reliable apps of any size. This repository demonstrates the principles I apply at work every day in more than 2,000 lines of thoroughly commented code and has an accompanying long-form guide to building real-world Halogen applications.

Using Halogen 4? Browse the repository at the tag for Halogen 4. Upgrading from Halogen 4 to Halogen 5? See the PR which migrated this repository to Halogen 5.

I’m a senior software engineer at Awake Security (and previously at CitizenNet). Both companies have large production PureScript applications that have remained reliable, understandable, and maintainable as they scale. I’m convinced PureScript is the best language available today for most single-page applications.

This repository follows the RealWorld spec to implement a Medium clone called Conduit using Halogen. It’s large enough to demonstrate real world examples (CRUD, state management, scalable architecture, type classes, components, etc.) but not so large as to be overwhelming.

Installation

You can install and build the project with:

# clone the repository
git clone https://github.com/thomashoneyman/purescript-halogen-realworld
cd purescript-halogen-realworld

# install dependencies
yarn install

# build the project and run the local server
yarn build-serve

If you are doing local development, I'd recommend running yarn watch-dev while working, and only use yarn watch-serve when you need to view how your changes reflect in the application (Parcel takes some time to run).

Learning PureScript

This project is intended to give non-PureScript developers a taste of what a small application in the language looks like, and to give advanced beginners in PureScript a resource to feel comfortable building reliable applications of their own.

PureScript is a delightful language that becomes only more interesting and rewarding the more you use it and the larger your application becomes; if you haven’t yet tried it out, I encourage you to do so. Not convinced? Kris Jenkins has a lovely talk about PureScript which might change your mind.

Resources

The PureScript community is overwhelmingly warm and helpful. If you would like some help getting started, please consider joining the official Discourse and functional programming Slack (invite link). You may also want to check out:

  1. PureScript by Example, which will teach you PureScript from scratch and was written by the language’s creator, Phil Freeman. While the official book has not been updated for the latest version of the compiler, this link is to an up-to-date fork of the book.
  2. Jordan Martinez’s PureScript reference, which has a broad overview of dozens of topics in PureScript and functional programming.
  3. The (warning: currently in rough draft form) handbook which explains the theory & principles at work in this application in-depth, which will be useful to help take you from advanced beginner to advanced intermediate in the language.
  4. The official Halogen guide, which will teach you how to use the Halogen framework to write components.

Contributing

PRs are welcome! Any functional changes will need to remain compliant with the RealWorld spec, and I may re-word documentation changes to fit with the voice used throughout the repository.

purescript-halogen-realworld's People

Contributors

thomashoneyman avatar jfraudeau avatar matthew-hilty avatar alex-ketch avatar davezuch avatar safareli avatar

Stargazers

Roman avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.