snackycracky / halogen-boilerplate

Bootstrap Halogen Project

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

halogen-boilerplate

This is a boilerplate for starting a real world project using the purescript-halogen library for declarative user interfaces.

Features

Prerequisites

This guide assumes you already have Git and Node.js installed with npm somewhere on your path.

npm install --global purescript pulp psc-package bower

Getting started

First clone the repo and step into it:

git clone https://github.com/jimmyhuco/halogen-boilerplate.git hello-halogen
cd hello-halogen
bower i

Building

The project can now be built with:

npm run build

This will build the PureScript source code and produce a bundled JS file as dist/js/app.js.

If you open dist/index.html you should now have a basic working Halogen app.

You can also use the command:

npm run watch

To start a process that will watch the source files and trigger a reload whenever they are modified. Alternatively...

Fast watching with purs ide

If you're using an editor that supports purs ide, there's an option for getting near-instant builds of the app while you work on it:

npm install
npm run watch-fast

First, you should have to install Webpack, and then it will start a watch process to rebundle the app whenever the output files are changed. Since purs ide rebuilds modules on save, this means you can use this much faster bundle-only rebuild script.

Note

About

Bootstrap Halogen Project


Languages

Language:PureScript 99.6%Language:JavaScript 0.4%