diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md new file mode 100644 index 00000000..c49a4bc9 --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1,12 @@ +**Description of the change** + +Clearly and concisely describe the purpose of the pull request. If this PR relates to an existing issue or change proposal, please link to it. Include any other background context that would help reviewers understand the motivation for this PR. + +--- + +**Checklist:** + +- [ ] Added the change to the changelog's "Unreleased" section with a reference to this PR (e.g. "- Made a change (#0 by @)") +- [ ] Linked any existing issues or proposals that this pull request should close +- [ ] Updated or added relevant documentation +- [ ] Added a test for the contribution (if applicable) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 00000000..9e1f3bfb --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,133 @@ +name: CI + +on: + pull_request: + push: + branches: [master] + release: + types: [published] + + +env: + SERVER_ASSET: trypurescript-server + CLIENT_ASSET: trypurescript-client + +jobs: + build_server: + name: Build server + # Note that this must be kept in sync with the version of Ubuntu which the + # Try PureScript server is running, otherwise the server binary may fail to + # run. + runs-on: ubuntu-20.04 + steps: + - uses: actions/checkout@v2 + + - uses: haskell/actions/setup@v1 + with: + enable-stack: true + stack-version: "2.5.1" + stack-no-global: true + + - name: Cache dependencies + uses: actions/cache@v2 + with: + path: ~/.stack + key: ${{ runner.os }}-stack-${{ hashFiles('stack.yaml.lock') }}-${{ hashFiles('trypurescript.cabal') }} + + - name: Build server code + run: stack --no-terminal -j1 build + + - name: Build server assets + if: github.event_name == 'release' + run: | + mkdir ${{ env.SERVER_ASSET }} + cp $(stack path --dist-dir)/build/trypurescript/trypurescript ${{ env.SERVER_ASSET }}/ + cp LICENSE ${{ env.SERVER_ASSET }}/ + cp -r deploy/ ${{ env.SERVER_ASSET }}/ + cp -r staging/ ${{ env.SERVER_ASSET}}/ + tar czf ${{ env.SERVER_ASSET }}.tar.gz -C ${{ env.SERVER_ASSET }}/ . + + - name: Persist server assets + uses: actions/upload-artifact@v2 + if: github.event_name == 'release' + with: + name: ${{ env.SERVER_ASSET }}.tar.gz + path: ${{ env.SERVER_ASSET }}.tar.gz + retention-days: 1 + + build_client: + name: Build client + # Note that this must be kept in sync with the version of Ubuntu which the + # Try PureScript server is running, otherwise the server binary may fail to + # run. + runs-on: ubuntu-20.04 + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v2 + + - name: Build client code + run: | + cd client + npm install + npm run build + npm run test + npm run build:production + npm run bundle + + - name: Check SharedConfig.purs versions + run: | + cd client + cp src/Try/SharedConfig.purs sharedConfig.out + node updateSharedConfigVersions.mjs sharedConfig.out + diff src/Try/SharedConfig.purs sharedConfig.out || { + echo 'PureScript and/or package set versions in "client/src/Try/SharedConfig.purs"' + echo 'do not match the versions extracted from "stack.yaml" and "staging/packages.dhall".' + echo 'Please run "cd client && npm run updateConfigVersions". CI will fail until then.' + exit 1 + } + + - name: Build client assets + if: github.event_name == 'release' + run: | + mkdir ${{ env.CLIENT_ASSET }} + cp LICENSE ${{ env.CLIENT_ASSET }}/ + cp -r client/public/ ${{ env.CLIENT_ASSET }}/ + tar czf ${{ env.CLIENT_ASSET }}.tar.gz -C ${{ env.CLIENT_ASSET }}/ . + + - name: Persist client assets + uses: actions/upload-artifact@v2 + if: github.event_name == 'release' + with: + name: ${{ env.CLIENT_ASSET }}.tar.gz + path: ${{ env.CLIENT_ASSET }}.tar.gz + retention-days: 1 + + release: + name: Release + # Note that this must be kept in sync with the version of Ubuntu which the + # Try PureScript server is running, otherwise the server binary may fail to + # run. + runs-on: ubuntu-20.04 + if: github.event_name == 'release' + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + needs: + - build_server + - build_client + steps: + - name: Retrieve server assets + uses: actions/download-artifact@v2 + with: + name: ${{ env.SERVER_ASSET }}.tar.gz + + - name: Retrieve client assets + uses: actions/download-artifact@v2 + with: + name: ${{ env.CLIENT_ASSET }}.tar.gz + + - name: Upload server and client assets + uses: softprops/action-gh-release@v1 + with: + files: | + ${{ env.SERVER_ASSET }}.tar.gz + ${{ env.CLIENT_ASSET }}.tar.gz diff --git a/.gitignore b/.gitignore index 884a06b7..a7fcc9b6 100644 --- a/.gitignore +++ b/.gitignore @@ -13,3 +13,6 @@ cabal.sandbox.config *.chi *.chs.h *.lksh* +bundle/ +client/public/js/output +client/client.js diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 484eb6b1..00000000 --- a/.travis.yml +++ /dev/null @@ -1,45 +0,0 @@ -sudo: false - -# Choose a lightweight base image; we provide our own tools. -language: c - -cache: - directories: - - $HOME/.ghc - - $HOME/.cabal - - $HOME/.stack - -addons: - apt: - packages: - - libgmp-dev - -before_install: - - mkdir -p ~/.local/bin - - export PATH=$HOME/.local/bin:$PATH - - curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack' - - -install: - - echo "$(ghc --version) [$(ghc --print-project-git-commit-id 2> /dev/null || echo '?')]" - - travis_wait stack --no-terminal -j1 --install-ghc build --only-dependencies - -script: - - travis_wait stack --no-terminal -j1 build - -notifications: - email: true - -before_deploy: - - mkdir bundle - - cp `stack path --dist-dir`/build/trypurescript/trypurescript bundle/ - - cp LICENSE bundle/ - - tar czf trypurescript.tar.gz -C bundle/ . - -deploy: - provider: releases - api_key: $RELEASE_KEY - file: trypurescript.tar.gz - skip_cleanup: true - on: - tags: true diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 00000000..e73a1d66 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,287 @@ +# Changelog + +Notable changes to this project are documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). + +## [Unreleased] + +Breaking changes: + +New features: + +Bugfixes: + +Other improvements: + +## [v2023-12-22.1](https://github.com/purescript/trypurescript/releases/tag/v2023-12-22.1) + +Other improvements: +- Bump PureScript to `0.15.13` (#306 by @JordanMartinez) +- Update to latest package set (#306 by @JordanMartinez) + +## [v2023-07-18.1](https://github.com/purescript/trypurescript/releases/tag/v2023-07-18.1) + +Other improvements: +- Bump PureScript to `0.15.10` (#310 by @JordanMartinez) +- Update to latest package set (#310 by @JordanMartinez) + +## [v2023-03-06.1](https://github.com/purescript/trypurescript/releases/tag/v2023-03-06.1) + +Other improvements: +- Bump PureScript to `0.15.8` (#305 by @JordanMartinez) +- Update to latest package set (#305 by @JordanMartinez) + +## [v2022-12-12.1](https://github.com/purescript/trypurescript/releases/tag/v2022-12-12.1) + +Other improvements: +- Update main example to note that editor state is persisted in the URL (#300 by @thomashoneyman) +- Update PureScript to `0.15.7` (#302 by @JordanMartinez) +- Update to latest package set (#302 by @JordanMartinez) + +## [v2022-09-10.1](https://github.com/purescript/trypurescript/releases/tag/v2022-09-10.1) + +New features: +- Remove `localStorage` for session storage, persist editor state in URL query param (#299 by @ptrfrncsmrph) + +## [v2022-08-16.1](https://github.com/purescript/trypurescript/releases/tag/v2022-08-16.1) + +Other improvements: +- Update `es-module-shims` to 1.5.12 (#298 by @andys8) + +## [v2022-08-12.1](https://github.com/purescript/trypurescript/releases/tag/v2022-08-12.1) + +Bugfixes: +- Add missing `react-dom/client` shim (#294 by @andys8) +- Fix double `main` invocation (#295 by @JordanMartinez) +- Stop loading hang when using query params to show compiled JS output (#296 by @JordanMartinez) + +Other improvements: +- Update package set to latest `0.15.4` one (#294) by @andys8) + +## [v2022-07-21.1](https://github.com/purescript/trypurescript/releases/tag/v2022-07-21.1) + +Bugfixes: +- Fix `Reference Error: main is not defined` bug: (#288 by @JordanMartinez) +- Fix `Unknown type Effect` bug in examples (#292 by @ptrfrncsmrph) +- Fix NPM dependency shims on Firefox 100+ (#289 by @JordanMartinez) +- Fix import maps for React deps by bumping version to 17.0.2 (#289 by @JordanMartinez) + +Other improvements: +- Update `es-module-shims` to 1.5.9 (#289 by @JordanMartinez) + +## [v2022-07-15.1](https://github.com/purescript/trypurescript/releases/tag/v2022-07-15.1) + +Other improvements: +- Drop requirement that module name be `Main` (#285 by @JordanMartinez) +- Fixes compiler warnings in examples (#286 by @JordanMartinez) +- Support cookbook repo UI recipes by adding element to `frame.html` (#286 by @JordanMartinez) +- Update to latest package set (#287 by @JordanMartinez) + +## [v2022-07-12.1](https://github.com/purescript/trypurescript/releases/tag/v2022-07-12.1) + +Other improvements: +- Update to PureScript 0.15.4 (#281 by @JordanMartinez) + +## [v2022-06-24.1](https://github.com/purescript/trypurescript/releases/tag/v2022-06-24.1) + +Other improvements: +- Update to PureScript 0.15.3 (#281 by @JordanMartinez) +- Update codebase to GHC 9.2.3 (#281 by @JordanMartinez) + +## [v2022-06-18.1](https://github.com/purescript/trypurescript/releases/tag/v2022-06-18.1) + +New features: +- Clearly indicate PureScript and package set version (#280 by @JordanMartinez) + +Bugfixes: +- Stop double `main` invocation by updating `es-module-shims` to 1.5.6 (#279 by @JordanMartinez) + +## [v2022-06-10.2](https://github.com/purescript/trypurescript/releases/tag/v2022-06-10.2) + +Other improvements: +- Update client to 0.15.2; bundle via esbuild (#278 by @JordanMartinez) + +## [v2022-06-10.1](https://github.com/purescript/trypurescript/releases/tag/v2022-06-10.1) + +Bugfixes: +- Fix the URL used for getting module dependencies of `Main` (#277 by @JordanMartinez) +- Update alias to refer to correct location on server (#277 by @JordanMartinez) + +## [v2022-06-08.1](https://github.com/purescript/trypurescript/releases/tag/v2022-06-08.1) + +Breaking changes: +- update compiler to v0.15.2 (#275 by @JordanMartinez) +- Update package set to latest `0.15.2` one (#275 by @JordanMartinez) + +## [v2022-02-25.1](https://github.com/purescript/trypurescript/releases/tag/v2022-02-25.1) + +Breaking changes: +- Update compiler to v0.14.7 (#271 by @JordanMartinez) + +New features: + +Bugfixes: + +Other improvements: +- Update package set to latest 0.14.5 one (#271 by @JordanMartinez) + +## [v2022-02-05.1](https://github.com/purescript/trypurescript/releases/tag/v2022-02-05.1) + +Breaking changes: + +New features: + +Bugfixes: +- Use `replaceState` for setting query params (#266 by @ptrfrncsmrph) +- Display missing FFI dependency error message to user (#268 by @ptrfrncsmrph) + +Other improvements: + +## [v2021-11-30.1](https://github.com/purescript/trypurescript/releases/tag/v2021-11-11.1) + +Breaking changes: + +New features: + +Bugfixes: + +Other improvements: +- Fix double-encoding of quotation marks (#261 by @rhendric) + +## [v2021-11-11.1](https://github.com/purescript/trypurescript/releases/tag/v2021-11-11.1) + +Breaking changes: + +New features: + +Bugfixes: +- Fixed `encode` not replacing all instances of special characters (#254 by @jy14898) +- Fixed up-to-five-second hangs between the loading icon disappearing and the content rendering (#256 @mikesol) + +Other improvements: +- Update `purescript` dependency to `0.14.5` (#257 by @JordanMartinez) +- Update package set to `psc-0.14.5-20211111` (#260 by @JordanMartinez) + +## [v2021-08-25.1](https://github.com/purescript/trypurescript/releases/tag/v2021-08-25.1) - 2021-08-25 + +Other improvements: +- Update `purescript` dependency to `0.14.4` (#253 by @JordanMartinez) + +## [v2021-08-23.1](https://github.com/purescript/trypurescript/releases/tag/v2021-08-23.1) - 2021-08-23 + +Other improvements: +- Update to the August 23, 2021 package set (#252 by @thomashoneyman) + +## [v2021-07-07.1](https://github.com/purescript/trypurescript/releases/tag/v2021-07-07.1) - 2021-07-07 + +Other improvements: +- Update to build against PureScript 0.14.3 (#238 by @thomashoneyman) + +## [v2021-07-04.1](https://github.com/purescript/trypurescript/releases/tag/v2021-07-04.1) - 2021-07-04 + +Bugfixes: +- Support use of JS `const` keyword in `requireRegex` (#237 by @ptrfrncsmrph) + +## [v2021-06-18.1](https://github.com/purescript/trypurescript/releases/tag/v2021-06-18.1) - 2021-06-18 + +Other improvements: + +- Migrated CI to GitHub Actions (#232 by @thomashoneyman) +- Fixed mangled 'Compiled ModuleName' output (#228 by @JordanMartinez) +- Updated dev instructions: create valid symbolic link across OSes (#226 by @JordanMartinez) +- Added a changelog (#229 by @JordanMartinez) +- Updated PureScript dependency to v0.14.2 (#230 by @JordanMartinez) +- Sped up server slightly by using `rebuildModule'` (#230 by @JordanMartinez) + +## [v2021-05-29.1](https://github.com/purescript/trypurescript/releases/tag/v2021-05-29.1) - 2021-05-29 + +This release officially adds support for PureScript 0.14 to Try PureScript, among many other (largely internal) improvements and updates. + +- Updated the compiler and package set for PureScript 0.14 (#209, #213, #224 by @thomashoneyman, #223 by @JordanMartinez) +- Updated local development instructions (#221 by @JordanMartinez, #225 by @thomashoneyman) +- Added support for loading files from GitHub repositories and migrated examples into the Try PureScript repository (#218 by @thomashoneyman) +- Migrated the client to Halogen from JQuery (#215 by @thomashoneyman) +- Migrated the client to `argonaut-codecs` from `foreign-generic` (#212, #217 by @thomashoneyman) +- Migrated the client to `Aff` from `ContT` (#208 by @thomashoneyman) +- Added fixtures to test API responses (#211 by @thomashoneyman) +- Removed unused pragmas, imports, and definitions from server code (#206 by @thomashoneyman) +- Allowed form submission in the Try PureScript iframe (#203 by @mikesol) +- Switch to use a svg favicon with ico fallback (#191 by @milesfrain) +- Implement `encode` in PureScript instead of in FFI (#186 by @maxdeviant) + +## [v2020-07-11.1](https://github.com/purescript/trypurescript/releases/tag/v2020-07-11.1) - 2020-07-11 + +- Enable automated SSL certificate renewal (#184, @hdgarrood) +- Remove unused `parsec` dependency (#178, @hdgarrood) +- Only listen on 127.0.0.1 (#177, @hdgarrood) + +## [v2020-05-26.1](https://github.com/purescript/trypurescript/releases/tag/v2020-05-26.1) - 2020-05-26 + +- Update to PureScript v0.13.8 (#175, @hdgarrood +- Make the whole package set available (#173, @hdgarrood, @thomashoneyman) +- Do away with version numbers (#176, @hdgarrood) + +## [v0.13.7](https://github.com/purescript/trypurescript/releases/tag/v0.13.7) - 2020-05-03 + +- Fixed help link (#165, @hdgarrood) +- Update API documentation in readme (#168, @hdgarrood) + +## [v0.13.6](https://github.com/purescript/trypurescript/releases/tag/v0.13.6) - 2020-05-03 + +- Updated to v0.13.6 of the PureScript compiler +- Made minor tweaks to get deploys working + +## [v0.13.5](https://github.com/purescript/trypurescript/releases/tag/v0.13.5) - 2020-05-02 + +- Updated to v0.13.5 of the compiler (@natefaubion) +- Removed backends, now serve individual modules on demand (@natefaubion, @gabejohnson, #128, #136) +- Hosted the client ourselves rather than using GH pages +- Put all source files in one branch (@gabejohnson, #135) +- Fixed gist navigation within the iframe (@natefaubion, #140) +- Used different sourceURL syntax per warnings (@natefaubion, #141) +- Switched to spago for managing PS dependencies (@hdgarrood, #147, #150) +- Built the frontend in CI (@hdgarrood, #152) +- Mostly automated deployments (@hdgarrood) + +## [v0.11.7](https://github.com/purescript/trypurescript/releases/tag/v0.11.7) - 2017-11-30 + +Update to 0.11.7 (@Thimoteus) + +## [v0.11.6.1](https://github.com/purescript/trypurescript/releases/tag/v0.11.6.1) - 2017-09-01 + +Return warnings from API + +## [v0.11.6](https://github.com/purescript/trypurescript/releases/tag/v0.11.6) - 2017-07-11 + +Updates for the v0.11.6 compiler + +## [v0.11.2](https://github.com/purescript/trypurescript/releases/tag/v0.11.2) - 2017-04-02 + +Update to 0.11.2 compiler + +## [v0.11.1](https://github.com/purescript/trypurescript/releases/tag/v0.11.1) - 2017-04-01 + +Updates for 0.11.1 compiler. + +## [v0.10.5](https://github.com/purescript/trypurescript/releases/tag/v0.10.5) - 2017-01-16 + +Update compiler and add basic type search + +## [v0.10.4](https://github.com/purescript/trypurescript/releases/tag/v0.10.4) - 2017-01-02 + +Update to compiler v0.10.4 + +## [v0.10.3](https://github.com/purescript/trypurescript/releases/tag/v0.10.3) - 2016-12-18 + +Update to 0.10.3, use JSON errors. + +## [v0.10.2](https://github.com/purescript/trypurescript/releases/tag/v0.10.2) - 2016-11-11 + +New version using compiler v0.10.2 + +## [v0.9.1.1](https://github.com/purescript/trypurescript/releases/tag/v0.9.1.1) - 2016-06-17 + +## [v0.9.1](https://github.com/purescript/trypurescript/releases/tag/v0.9.1) - 2016-06-17 + +## [v0.8.2.0](https://github.com/purescript/trypurescript/releases/tag/v0.8.2.0) - 2016-03-11 + +Updates for v0.8.2 compiler diff --git a/LICENSE b/LICENSE index 91038416..732bb0e0 100644 --- a/LICENSE +++ b/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2013-16 PureScript +Copyright (c) 2013-20 PureScript All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: diff --git a/README.md b/README.md index 0911cfa3..7e8671d0 100644 --- a/README.md +++ b/README.md @@ -1,79 +1,186 @@ -# PureScript API +# Try PureScript -[![Build Status](https://api.travis-ci.org/purescript/trypurescript.svg?branch=master)](http://travis-ci.org/purescript/trypurescript) +[![Build Status](https://github.com/purescript/trypurescript/workflows/CI/badge.svg?branch=master)](https://github.com/purescript/trypurescript/actions?query=workflow%3ACI+branch%3Amaster) -Very basic web service which wraps the PureScript compiler. +[Try PureScript](https://try.purescript.org) is an online PureScript code editor for quickly experimenting with PureScript code snippets and ideas. It consists of a client and a server component, both of which live within this repository. -[Client code](https://github.com/purescript/trypurescript/tree/gh-pages) +## Features: -## API +- Writing code using the [Ace Editor](http://ace.c9.io) +- Automatic compilation +- PureScript syntax highlighting +- Run and print output or show resulting JavaScript +- Multiple view modes: code, output or both +- Shareable code and editor state via URL +- Load PureScript code from GitHub Gists or repository files -### Compile PureScript code +### Control Features via the Query String -**POST /compile** +Most of these features can be controlled not only from the toolbar, but also using the [query parameters](https://en.wikipedia.org/wiki/Query_string): -- Request body: PureScript code -- Response body: Either `{ js: "..." }` or `{ error: "..." }` -- Status code: 200 (success) +- **Load From GitHub Repo**: Load a PureScript file from a GitHub repository using the `github` parameter + - Format: `github=////.purs` + - Example: `github=/purescript/trypurescript/master/client/examples/Main.purs`. + - Notes: the file should be a single PureScript module with the module name `Main`. -The response does not use error codes, to make it easier to use the API from another domain using CORS. +- **Load From Gist**: Load PureScript code from a gist using the `gist` parameter + - Format: `gist=` + - Example: `gist=37c3c97f47a43f20c548` + - Notes: the file should be named `Main.purs` with the module name `Main`. -The output code will contain references to preloaded modules using `require` calls. To run these files in the browser, it is necessary to either use a `require` shim (such as require1k), or replace these calls and deploy a bundle of precompiled modules (the Try PureScript client uses the second approach). +- **Load From URL**: Load compressed PureScript code using the `code` parameter + - Managed by Try PureScript and updated on editor state change to create shareable URLs + - Format: `code=` + - Example: `code=LYewJgrgNgpgBAWQIYEsB2cDuALGAnGIA` will set the editor state to the single line `module Main where` -## Configuration +- **View Mode**: Control the view mode using the `view` parameter + - Options are: `code`, `output`, `both` (default) + - Example: `view=output` will only display the output -The application takes the following arguments on the command line: +- **Auto Compile**: Automatic compilation can be turned off using the `compile` parameter + - Options are: `true` (default), `false` + - Example: `compile=false` will turn auto compilation off -- port number -- a list of input source files +- **JavaScript Code Generation**: Print the resulting JavaScript code in the output window instead of the output of the program using the `js` parameter + - Options are: `true`, `false` (default) + - Example: `js=true` will print JavaScript code instead of the program's output -### Example +### Which Libraries Are Available? - dist/build/trypurescript/trypurescript 8081 'bower_components/purescript-*/src/**/*.purs' - -# Development +Try PureScript aims to provide a complete, recent package set from . The available libraries are those listed in [`staging/spago.dhall`](./staging/spago.dhall), at the versions in the package set mentioned in [`staging/packages.dhall`](./staging/packages.dhall). -## 1. Client setup +## Development -``` +### 1. Shared setup + +These steps should be performed whether you are working on the server, the client, or both. + +```sh +# Clone into the repository git clone git@github.com:purescript/trypurescript.git cd trypurescript -git co gh-pages +``` + +### 2. Local compile server setup + +This step sets up a local server for Try PureScript. You can skip this step if you just want to use the client with the production server. -bower install -npm run build -npm run bundle +```sh +# Build the trypurescript executable +stack build + +# Set up the PureScript environment for the server +cd staging +spago build + +# Ensure the compiled JavaScript is available to the client via symbolic link. +ln -s "$PWD/output" "$PWD/../client/public/js/output" -httpserver 8080 #eg with: alias httpserver='python -m SimpleHTTPServer' -open http://localhost:8080 +# Then, start the server. +# +# Below, we disable glob expansion via `set -o noglob` to ensure that globs are +# passed to `purs` unchanged. +# +# We run this in a subshell so that setting noglob only lasts for the duration +# of the command and no longer. +(set -o noglob && stack exec trypurescript 8081 $(spago sources)) + +# Should output that it is compiling the sources (first time) +# Then: Setting phasers to stun... (port 8081) (ctrl-c to quit) ``` -## 2. Work with local compile server +### 3. Client setup + +```sh +# Install development dependencies +cd client +npm install +# Use `serve:dev` if you are using a local Try PureScript server, +# e.g. you followed the instructions in step 1. +# +# Use `serve:production` if you would like +# to test the client against the production Try PureScript server. +# Note: the production server may not match the package set you have locally. +npm run serve:(dev|production) + +# Try PureScript is now available on localhost:8080 ``` -git clone git@github.com:purescript/trypurescript.git -cd trypurescript -stack build +### 4. Choosing a Tag + +The built-in examples for Try PureScript are loaded from this GitHub repository. To change the tag that the examples are loaded from, you'll need to touch three files: -# use one of the backends -cd staging/core -# get the sources of the deps -psc-package update +* `client/config/dev/Try.Config.purs` +* `client/config/prod/Try.Config.purs` +* `client/examples/Main.purs`, in the `fromExample` function. -# note: globs like **/src/** do not work -stack exec trypurescript 8081 ".psc-package/psc-0.11.6/*/*/src/**/*.purs" "src/*.purs" -# should output that is is compiling the sources (first time) -# then: Setting phasers to stun... (port 8081) (ctrl-c to quit) +If you are preparing a release or if you need to adjust examples in development, you should change the tag in these three places (and ensure you're using the same tag in each place!). + +## Server API + +The server is a very basic web service which wraps the PureScript compiler, allowing clients to send PureScript code to be compiled and receiving either compiled JS or error messages in response. +It is hosted at . + +### Compile PureScript code + +#### POST /compile + +- Request body: PureScript code defining a module whose name must be Main +- Status code: 200 (success) + +Response body on compilation success: + +```javascript +{ + "js": "...", // a string containing JavaScript code + "warnings": [ ... ] // an array of warnings, using the same format as the + // compiler's --json-errors flag +} ``` -## 3. Point client to local compile server +Response body on compilation failure: -(instead of the ones at try.purescript.org) +```javascript +{ + "error": { + "tag": "CompilerErrors", + "contents": [ ... ] // an array of errors, using the same format as the + // compiler's --json-errors flag + } +} ``` -# edit API.purs - , compile: compile "http://localhost:8081" - , getBundle: getDefaultBundle "http://localhost:8081" +Response body on other errors (eg, the name of the module in request body was not Main, or the request body was too large) +```javascript +{ + "error": { + "tag": "OtherError", + "contents": "..." // a string containing an error message + } +} ``` + +Note that the API returns a 200 response in all of the above cases; in particular, if the code in the request body fails to compile and the API returns errors, this is still considered a success. +Among other things, this makes it easier to use the API from another domain using CORS. + +The output code will contain references to any imported modules using `require` calls. +To run these files in the browser, it is necessary to either use a `require` shim (such as require1k), or replace these calls and deploy a bundle of precompiled modules. +The Try PureScript client uses the first approach. + +#### GET /output/:module/(index.js|foreign.js) + +The server exposes the compiled JS for all of the modules it has access to. +If the compiled JavaScript code in the response includes a `require` call such as `require(../Web.HTML/index.js)`, then the client is expected to arrange things so that this `require` call provides access to the JavaScript code available at the URL path `/output/Web.HTML/index.js`, via a shim or otherwise. + +### Configuration + +The server application takes the following arguments on the command line: + +- port number +- a list of input source files + +#### Example + + trypurescript 8081 'bower_components/purescript-*/src/**/*.purs' diff --git a/RELEASE.md b/RELEASE.md new file mode 100644 index 00000000..e800d072 --- /dev/null +++ b/RELEASE.md @@ -0,0 +1,94 @@ +# Release + +## Instructions for Redeploying Try PureScript + +After making a new compiler release, do the following to redeploy Try PureScript using the new compiler. + +1. Submit a PR with the following changes: + - In `stack.yaml`, + - update the `resolver` to match the same one used in the PureScript repo + - update `purescript` to use its new version. + - Update the package set (see next section's instructions). + - Update the shared config by running `cd client && npm run updateConfigVersions`. + - Update the changelog to include the next release's date. +2. Once the PR is merged, create a new GitHub tagged release using `vYYYY-MM-DD.X` (where `X` is usually `1` or the release attempt) as the version schema. The release will trigger a GitHub Actions build. +3. Wait for the GitHub Actions build to finish (it builds the assets) +4. Run `./deploy/run.sh vX-X-X.1`, replacing `vX-X-X.1` with the version you created. + - Note: if you're updating the compiler, be sure to push the corresponding tag to [`purescript-metadata`](https://github.com/purescript/purescript-metadata). Otherwise, `spago install` will fail on the server and prevent the server from starting. + +## Updating the Package Set + +The try.purescript.org server only has a limited amount of memory. If the package set we use in deployment is too large, the server will run out of memory. + +Before deploying an updated package set, someone (your reviewer) should check that the memory required to hold the package set's externs files does not exceed that of the try.purescript.org server. + +Update the package set by doing the following. Each step is explained below: + +### Summary + +```sh +pushd staging +spago upgrade-set +cat > spago.dhall << EOF +{ name = "try-purescript-server" +, dependencies = [] : List Text +, packages = ./packages.dhall +, sources = [ "src/**/*.purs" ] +} +EOF +spago ls packages | cut -f 1 -d ' ' | xargs spago install +popd +pushd client +npm run updateConfigVersions +popd +# add any new shims +# update ES Module Shims (if needed) +``` + +### Step-by-Step Explanation + +1. Update the `upstream` package set in `staging/packages.dhall`: + + ``` + $ pushd staging && spago upgrade-set && popd + ``` + +2. Set the `dependencies` key in the `spago.dhall` file to be an empty list. This will require a type annotation of `List Text`: + + ```dhall + { name = "try-purescript-server" + , dependencies = [] : List Text + , packages = ./packages.dhall + , sources = [ "src/**/*.purs" ] + } + ``` + +3. For `staging/spago.dhall`, install all packages in the package set by running this command: + + ``` + $ spago ls packages | cut -f 1 -d ' ' | xargs spago install + ``` + +4. Update the `client/src/Try/SharedConfig.purs` file by running this command in `client`: + + ```console + $ npm run updateConfigVersions + ``` + +5. If any packages need NPM dependencies, you can try adding their shims to the import map in `client/public/frame.html` + - Open up the `generator.jspm.io` URL in the comment + - Use the 'Add Dependency' search bar to find the NPM dependency + - If it exists but doesn't exist in that CDN, you can try another one or [open an issue on `jspm/project`](https://github.com/jspm/project#issue-queue-for-the-jspm-cdn) + - Update the version to the one you need once added + - If needed, include other files from that dependency + - Copy and paste the content into the `client/public/frame.html` file + - Ensure `es-module-shims` has version `1.5.9` or greater. + +6. If `es-module-shims` releases a new version, you can calculate its SHA-384 via + + ```console + $ ESM_VERSION=1.5.5 + $ curl -L -o es-module-shims.js "https://ga.jspm.io/npm:es-module-shims@$ESM_VERSION/dist/es-module-shims.js" + $ echo "sha384-$(openssl dgst -sha384 -binary es-module-shims.js | openssl base64 -A)" + $ rm es-module-shims.js + ``` diff --git a/client/.gitignore b/client/.gitignore new file mode 100644 index 00000000..d4779c13 --- /dev/null +++ b/client/.gitignore @@ -0,0 +1,10 @@ +/node_modules/ +/package-lock.json +/output/ +/generated-docs/ +/.psc* +/.purs* +/.psa* +/.stack* +/public/js/index.js +.spago/ diff --git a/client/DEPENDENCIES b/client/DEPENDENCIES new file mode 100644 index 00000000..68dbe8e0 --- /dev/null +++ b/client/DEPENDENCIES @@ -0,0 +1,2365 @@ +Try PureScript uses the following dependencies. +Their licenses are reproduced here: + +ace + +Copyright (c) 2010, Ajax.org B.V. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + * Neither the name of Ajax.org B.V. nor the + names of its contributors may be used to endorse or promote products + derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL AJAX.ORG B.V. BE LIABLE FOR ANY +DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +jquery + +Copyright JS Foundation and other contributors, https://js.foundation/ + +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/jquery/jquery + +The following license applies to all parts of this software except as +documented below: + +==== + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +All files located in the node_modules and external directories are +externally maintained libraries used by this software which have their +own licenses; we recommend you read them, as their terms may differ from +the terms above. + +mathbox + +No license file found. bower.json says: +"MIT" + +purescript-aff + +Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "{}" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright {yyyy} {name of copyright owner} + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + +purescript-arraybuffer-types + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-arrays + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-behaviors + +Copyright (c) 2014-15 Phil Freeman + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +purescript-bifunctors + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-canvas + +No license file found. bower.json says: +"MIT" + +purescript-catenable-lists + +Copyright (c) 2015 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a +copy of this software and associated documentation files (the +"Software"), in the Software without restriction, including without +limitation the rights to use, copy, modify, merge, publish, distribute, +sublicense, and/or sell copies of the Software, and to permit persons to +whom the Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be included +in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-colors + +No license file found. bower.json says: +"MIT" + +purescript-console + +The MIT License (MIT) + +Copyright (c) 2015 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-const + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-contravariant + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-contravariant is based on substantial portions of the contravariant +Haskell library, which is used here under the terms of the BSD3 license: + + Copyright 2007-2015 Edward Kmett + + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + 1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + 3. Neither the name of the author nor the names of his contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS OR + IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE FOR + ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + +purescript-control + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-coroutines + +The MIT License (MIT) + +Copyright (c) 2015 Phil Freeman + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-datetime + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-distributive + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-dom + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-drawing + +No license file found. bower.json says: +"MIT" + +purescript-eff + +The MIT License (MIT) + +Copyright (c) 2015 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-either + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-enums + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-exceptions + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-exists + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +purescript-flare + +No license file found. bower.json says: +"MIT" + +purescript-foldable-traversable + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-foreign + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-foreign-generic + +The MIT License (MIT) + +Copyright (c) 2017 Phil Freeman + + Permission is hereby granted, free of charge, to any person obtaining a copy of + this software and associated documentation files (the "Software"), to deal in + the Software without restriction, including without limitation the rights to + use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of + the Software, and to permit persons to whom the Software is furnished to do so, + subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all + copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS + FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR + COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER + IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-foreign-generic uses code taken from the purescript-foreign library, +which is used under the terms of the MIT license, below: + + The MIT License (MIT) + + Copyright (c) 2014 PureScript + + Permission is hereby granted, free of charge, to any person obtaining a copy of + this software and associated documentation files (the "Software"), to deal in + the Software without restriction, including without limitation the rights to + use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of + the Software, and to permit persons to whom the Software is furnished to do so, + subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all + copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS + FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR + COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER + IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-free + +Copyright (c) 2014 Eric Thul + +Permission is hereby granted, free of charge, to any person obtaining a +copy of this software and associated documentation files (the +"Software"), in the Software without restriction, including without +limitation the rights to use, copy, modify, merge, publish, distribute, +sublicense, and/or sell copies of the Software, and to permit persons to +whom the Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be included +in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-freet + +The MIT License (MIT) + +Copyright (c) 2015 Phil Freeman + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-functions + +The MIT License (MIT) + +Copyright (c) 2015 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-functors + +The MIT License (MIT) + +Copyright (c) 2016 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-gen + +The MIT License (MIT) + +Copyright (c) 2017 Gary Burgess + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-generics + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-generics-rep + +No license file found. bower.json says: +"MIT" + +purescript-globals + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-graphs + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +purescript-identity + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-inject + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a +copy of this software and associated documentation files (the +"Software"), in the Software without restriction, including without +limitation the rights to use, copy, modify, merge, publish, distribute, +sublicense, and/or sell copies of the Software, and to permit persons to +whom the Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be included +in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-integers + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-invariant + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-jquery + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-js-date + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-js-timers + +The MIT License (MIT) + +Copyright (c) 2016 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-lazy + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-list-zipper + +The MIT License (MIT) + +Copyright (c) 2016 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-lists + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +----------------------------------------------------------------------------- + +The Glasgow Haskell Compiler License + +Copyright 2004, The University Court of the University of Glasgow. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +- Redistributions of source code must retain the above copyright notice, +this list of conditions and the following disclaimer. + +- Redistributions in binary form must reproduce the above copyright notice, +this list of conditions and the following disclaimer in the documentation +and/or other materials provided with the distribution. + +- Neither name of the University nor the names of its contributors may be +used to endorse or promote products derived from this software without +specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE UNIVERSITY COURT OF THE UNIVERSITY OF +GLASGOW AND THE CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, +INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +UNIVERSITY COURT OF THE UNIVERSITY OF GLASGOW OR THE CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. +The Glasgow Haskell Compiler License + +Copyright 2002, The University Court of the University of Glasgow. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +- Redistributions of source code must retain the above copyright notice, +this list of conditions and the following disclaimer. + +- Redistributions in binary form must reproduce the above copyright notice, +this list of conditions and the following disclaimer in the documentation +and/or other materials provided with the distribution. + +- Neither name of the University nor the names of its contributors may be +used to endorse or promote products derived from this software without +specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE UNIVERSITY COURT OF THE UNIVERSITY OF +GLASGOW AND THE CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, +INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +UNIVERSITY COURT OF THE UNIVERSITY OF GLASGOW OR THE CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. + + +purescript-maps + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +purescript-math + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-maybe + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-media-types + +The MIT License (MIT) + +Copyright (c) 2016 Gary Burgess + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-monoid + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-newtype + +The MIT License (MIT) + +Copyright (c) 2016 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-nonempty + +The MIT License (MIT) + +Copyright (c) 2016 Phil Freeman + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-nullable + +The MIT License (MIT) + +Copyright (c) 2015 Phil Freeman + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-parallel + +Copyright (c) 2014-15 PureScript + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +purescript-partial + +The MIT License (MIT) + +Copyright (c) 2015 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-prelude + +The MIT License (MIT) + +Copyright (c) 2015 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-profunctor + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-profunctor-lenses + +Copyright (c) 2015 Phil Freeman + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +purescript-proxy + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-quickcheck + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-random + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-react + +No license file found. bower.json says: +"MIT" + +purescript-react-dom + +No license file found. bower.json says: +"MIT" + +purescript-record + +MIT License + +Copyright (c) 2017 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + +purescript-refs + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-semirings + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-sets + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +purescript-signal + + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +purescript-slides + +Copyright (c) 2016, Gil Mizrahi +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +* Neither the name of [project] nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + + +purescript-smolder + +No license file found. bower.json says: +"LGPL-3.0+" + +purescript-st + +The MIT License (MIT) + +Copyright (c) 2015 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-strings + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-symbols + +The MIT License (MIT) + +Copyright (c) 2016 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-tailrec + +The MIT License (MIT) + +Copyright (c) 2015 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-thermite + +The MIT License (MIT) + +Copyright (c) 2014 Phil Freeman + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-transformers + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-tuples + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-type-equality + +No license file found. bower.json says: +"MIT" + +purescript-typelevel-prelude + +The MIT License (MIT) + +Copyright (c) 2016 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-unfoldable + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-unsafe-coerce + +The MIT License (MIT) + +Copyright (c) 2015 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +purescript-validation + +The MIT License (MIT) + +Copyright (c) 2014 PureScript + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +react + +BSD License + +For react-bower software + +Copyright (c) 2013-2014, Facebook, Inc. +All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: + + * Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + + * Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + + * Neither the name Facebook nor the names of its contributors may be used to + endorse or promote products derived from this software without specific + prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +underscore + +Copyright (c) 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative +Reporters & Editors + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. diff --git a/client/config/dev/Try.Config.purs b/client/config/dev/Try.Config.purs new file mode 100644 index 00000000..b3551a5c --- /dev/null +++ b/client/config/dev/Try.Config.purs @@ -0,0 +1,15 @@ +module Try.Config where + +import Prelude + +loaderUrl :: String +loaderUrl = "/js/output" + +compileUrl :: String +compileUrl = "http://localhost:8081" + +tag :: String +tag = "master" + +mainGitHubExample :: String +mainGitHubExample = "/purescript/trypurescript/" <> tag <> "/client/examples/Main.purs" diff --git a/client/config/prod/Try.Config.purs b/client/config/prod/Try.Config.purs new file mode 100644 index 00000000..936b4b10 --- /dev/null +++ b/client/config/prod/Try.Config.purs @@ -0,0 +1,15 @@ +module Try.Config where + +import Prelude + +loaderUrl :: String +loaderUrl = "https://compile.purescript.org/output" + +compileUrl :: String +compileUrl = "https://compile.purescript.org" + +tag :: String +tag = "master" + +mainGitHubExample :: String +mainGitHubExample = "/purescript/trypurescript/" <> tag <> "/client/examples/Main.purs" diff --git a/client/dependencies.sh b/client/dependencies.sh new file mode 100755 index 00000000..a65c9a35 --- /dev/null +++ b/client/dependencies.sh @@ -0,0 +1,10 @@ +echo Try PureScript uses the following dependencies. +echo Their licenses are reproduced here: + +for dir in bower_components/* +do + echo + basename $dir + echo + cat $dir/LICENSE* || (echo 'No license file found. bower.json says:' && cat $dir/bower.json | jq '.license') +done diff --git a/client/examples/ADTs.purs b/client/examples/ADTs.purs new file mode 100644 index 00000000..0f5214b5 --- /dev/null +++ b/client/examples/ADTs.purs @@ -0,0 +1,25 @@ +module Main where + +import Prelude + +import Effect (Effect) +import Effect.Console (logShow) +import Data.Map (Map, lookup, singleton) +import TryPureScript (render, withConsole) + +-- | A Name consists of a first name and a last name +data Name = Name String String + +-- | With compiler versions >= 0.8.2, we can derive +-- | instances for Eq and Ord, making names comparable. +derive instance eqName :: Eq Name +derive instance ordName :: Ord Name + +-- | The Ord instance allows us to use Names as the +-- | keys in a Map. +phoneBook :: Map Name String +phoneBook = singleton (Name "John" "Smith") "555-555-1234" + +main :: Effect Unit +main = render =<< withConsole do + logShow (lookup (Name "John" "Smith") phoneBook) diff --git a/client/examples/DoNotation.purs b/client/examples/DoNotation.purs new file mode 100644 index 00000000..2a01fc19 --- /dev/null +++ b/client/examples/DoNotation.purs @@ -0,0 +1,22 @@ +module Main where + +import Prelude +import Control.MonadPlus (guard) +import Effect (Effect) +import Effect.Console (logShow) +import Data.Array ((..)) +import Data.Foldable (for_) +import TryPureScript (render, withConsole) + +-- Find Pythagorean triples using an array comprehension. +triples :: Int -> Array (Array Int) +triples n = do + z <- 1 .. n + y <- 1 .. z + x <- 1 .. y + guard $ x * x + y * y == z * z + pure [x, y, z] + +main :: Effect Unit +main = render =<< withConsole do + for_ (triples 20) logShow diff --git a/client/examples/Generic.purs b/client/examples/Generic.purs new file mode 100644 index 00000000..ba7fdd5f --- /dev/null +++ b/client/examples/Generic.purs @@ -0,0 +1,58 @@ +module Main where + +import Prelude +import Effect (Effect) +import Effect.Console (logShow) +import Data.Generic.Rep (class Generic) +import Data.Eq.Generic (genericEq) +import Data.Ord.Generic (genericCompare) +import Data.Show.Generic (genericShow) +import TryPureScript (render, withConsole) + +data Address = Address + { city :: String + , state :: String + } + +data Person = Person + { first :: String + , last :: String + , address :: Address + } + +-- Generic instances can be derived by the compiler, +-- using the derive keyword: +derive instance genericAddress :: Generic Address _ + +derive instance genericPerson :: Generic Person _ + +-- Now we can write instances for standard type classes +-- (Show, Eq, Ord) by using standard definitions +instance showAddress :: Show Address where + show = genericShow + +instance eqAddress :: Eq Address where + eq = genericEq + +instance ordAddress :: Ord Address where + compare = genericCompare + +instance showPerson :: Show Person where + show = genericShow + +instance eqPerson :: Eq Person where + eq = genericEq + +instance ordPerson :: Ord Person where + compare = genericCompare + +main :: Effect Unit +main = render =<< withConsole do + logShow $ Person + { first: "John" + , last: "Smith" + , address: Address + { city: "Faketown" + , state: "CA" + } + } diff --git a/client/examples/Loops.purs b/client/examples/Loops.purs new file mode 100644 index 00000000..90ee46e5 --- /dev/null +++ b/client/examples/Loops.purs @@ -0,0 +1,14 @@ +module Main where + +import Prelude + +import Effect (Effect) +import Effect.Console (log) +import Data.Array ((..)) +import Data.Foldable (for_) +import TryPureScript (render, withConsole) + +main :: Effect Unit +main = render =<< withConsole do + for_ (10 .. 1) \n -> log (show n <> "...") + log "Lift off!" diff --git a/client/examples/Main.purs b/client/examples/Main.purs new file mode 100644 index 00000000..e7f21d5e --- /dev/null +++ b/client/examples/Main.purs @@ -0,0 +1,67 @@ +module Main where + +import Prelude + +import Data.Foldable (fold) +import Effect (Effect) +import TryPureScript (h1, h2, p, text, list, indent, link, render, code) + +main :: Effect Unit +main = + render $ fold + [ h1 (text "Try PureScript!") + , p (text "Try out the examples below, or create your own!") + , h2 (text "Examples") + , list (map fromExample examples) + , h2 (text "Share Your Code") + , p (text "The contents of the text editor are stored in the URL. To share your code you can simply copy the URL.") + , p (text "Additionally, a PureScript file can be loaded from GitHub from a gist or a repository. To share code using a gist, include the gist ID in the URL as follows:") + , indent (p (code (text " try.purescript.org?gist="))) + , p (fold + [ text "The gist should contain PureScript module named " + , code (text "Main") + , text " in a file named " + , code (text "Main.purs") + , text " containing your PureScript code." + ]) + , p (text "To share code from a repository, include the path to the source file as follows:") + , indent (p (code (text " try.purescript.org?github=////.purs"))) + , p (fold + [ text "The file should be a PureScript module named " + , code (text "Main") + , text " containing your PureScript code." + ]) + ] + where + fromExample { title, source } = + link ("https://github.com/purescript/trypurescript/master/client/examples/" <> source) (text title) + + examples = + [ { title: "Algebraic Data Types" + , source: "ADTs.purs" + } + , { title: "Loops" + , source: "Loops.purs" + } + , { title: "Operators" + , source: "Operators.purs" + } + , { title: "Records" + , source: "Records.purs" + } + , { title: "Recursion" + , source: "Recursion.purs" + } + , { title: "Do Notation" + , source: "DoNotation.purs" + } + , { title: "Type Classes" + , source: "TypeClasses.purs" + } + , { title: "Generic Programming" + , source: "Generic.purs" + } + , { title: "QuickCheck" + , source: "QuickCheck.purs" + } + ] diff --git a/client/examples/Operators.purs b/client/examples/Operators.purs new file mode 100644 index 00000000..b5a9919f --- /dev/null +++ b/client/examples/Operators.purs @@ -0,0 +1,22 @@ +module Main where + +import Prelude +import Effect (Effect) +import Effect.Console (log) +import TryPureScript (render, withConsole) + +type FilePath = String + +subdirectory :: FilePath -> FilePath -> FilePath +subdirectory p1 p2 = p1 <> "/" <> p2 + +-- Functions can be given an infix alias +-- The generated code will still use the original function name +infixl 5 subdirectory as + +filepath :: FilePath +filepath = "usr" "local" "bin" + +main :: Effect Unit +main = render =<< withConsole do + log filepath diff --git a/client/examples/QuickCheck.purs b/client/examples/QuickCheck.purs new file mode 100644 index 00000000..72079957 --- /dev/null +++ b/client/examples/QuickCheck.purs @@ -0,0 +1,23 @@ +module Main where + +import Prelude +import Data.Array (sort) +import Effect (Effect) +import Test.QuickCheck (quickCheck, (===)) +import TryPureScript (render, withConsole, h1, h2, p, text) + +main :: Effect Unit +main = do + render $ h1 $ text "QuickCheck" + render $ p $ text """QuickCheck is a Haskell library which allows us to assert properties +hold for our functions. QuickCheck uses type classes to generate +random test cases to verify those properties. +purescript-quickcheck is a port of parts of the QuickCheck library to +PureScript.""" + render $ h2 $ text "Sort function is idempotent" + render =<< withConsole do + quickCheck \(xs :: Array Int) -> sort (sort xs) === sort xs + render $ h2 $ text "Every array is sorted" + render $ p $ text "This test should fail on some array which is not sorted" + render =<< withConsole do + quickCheck \(xs :: Array Int) -> sort xs === xs diff --git a/client/examples/Records.purs b/client/examples/Records.purs new file mode 100644 index 00000000..0425e2a4 --- /dev/null +++ b/client/examples/Records.purs @@ -0,0 +1,20 @@ +module Main where + +import Prelude +import Effect (Effect) +import Effect.Console (log) +import TryPureScript (render, withConsole) + +-- We can write functions which require certain record labels... +showPerson :: forall r. { firstName :: String, lastName :: String | r } -> String +showPerson o = o.lastName <> ", " <> o.firstName + +-- ... but we are free to call those functions with any +-- additional arguments, such as "age" here. +main :: Effect Unit +main = render =<< withConsole do + log $ showPerson + { firstName: "John" + , lastName: "Smith" + , age: 30 + } diff --git a/client/examples/Recursion.purs b/client/examples/Recursion.purs new file mode 100644 index 00000000..0d511e60 --- /dev/null +++ b/client/examples/Recursion.purs @@ -0,0 +1,19 @@ +module Main where + +import Prelude +import Effect (Effect) +import Effect.Console (logShow) +import TryPureScript (render, withConsole) + +isOdd :: Int -> Boolean +isOdd 0 = false +isOdd n = isEven (n - 1) + +isEven :: Int -> Boolean +isEven 0 = true +isEven n = isOdd (n - 1) + +main :: Effect Unit +main = render =<< withConsole do + logShow $ isEven 1000 + logShow $ isEven 1001 diff --git a/client/examples/TypeClasses.purs b/client/examples/TypeClasses.purs new file mode 100644 index 00000000..b0ca16e8 --- /dev/null +++ b/client/examples/TypeClasses.purs @@ -0,0 +1,46 @@ +module Main where + +import Prelude +import Effect (Effect) +import Effect.Console (log) +import TryPureScript (render, withConsole) + +-- A type class for types which can be used with +-- string interpolation. +class Interpolate a where + interpolate :: a -> String + +instance interpolateString :: Interpolate String where + interpolate = identity + +instance interpolateInt :: Interpolate Int where + interpolate = show + +-- A type class for printf functions +-- (each list of argument types will define a type class instance) +class Printf r where + printfWith :: String -> r + +-- An instance for no function arguments +-- (just return the accumulated string) +instance printfString :: Printf String where + printfWith = identity + +-- An instance for adding another argument whose +-- type is an instance of Interpolate +instance printfShow :: (Interpolate a, Printf r) => Printf (a -> r) where + printfWith s a = printfWith (s <> interpolate a) + +-- Our generic printf function +printf :: forall r. (Printf r) => r +printf = printfWith "" + +-- Now we can create custom formatters using different argument +-- types +debug :: String -> Int -> String -> String +debug uri status msg = printf "[" uri "] " status ": " msg + +main :: Effect Unit +main = render =<< withConsole do + log $ debug "http://www.purescript.org" 200 "OK" + log $ debug "http://bad.purescript.org" 404 "Not found" diff --git a/client/package.json b/client/package.json new file mode 100644 index 00000000..1e937d81 --- /dev/null +++ b/client/package.json @@ -0,0 +1,29 @@ +{ + "name": "trypurescript-client", + "private": true, + "scripts": { + "clean": "rimraf output", + "test": "spago test --path config/dev/Try.Config.purs", + "build": "spago build --path config/dev/Try.Config.purs", + "build:dev": "spago bundle-app --path config/dev/Try.Config.purs --to client.js", + "build:production": "spago bundle-app --path config/prod/Try.Config.purs --purs-args '--censor-lib --strict' --to client.js", + "bundle": "esbuild --outfile=public/js/index.js --bundle --minify --platform=browser --format=iife --tree-shaking=true client.js", + "serve": "http-server public/ -o / --cors=\"Access-Control-Allow-Origin: *\" -c-1", + "serve:dev": "npm run build:dev && npm run bundle && npm run serve", + "serve:production": "npm run build:production && npm run bundle && npm run serve", + "updateConfigVersions": "node updateSharedConfigVersions.mjs src/Try/SharedConfig.purs" + }, + "devDependencies": { + "esbuild": "^0.14.43", + "http-server": "^14.1.0", + "purescript": "^0.15.2", + "purescript-psa": "^0.8.2", + "rimraf": "^2.5.4", + "spago": "^0.20.9" + }, + "dependencies": { + "ace-builds": "^1.5.0", + "jquery": "^1.12.4", + "lz-string": "^1.4.4" + } +} diff --git a/client/packages.dhall b/client/packages.dhall new file mode 100644 index 00000000..c21f1de2 --- /dev/null +++ b/client/packages.dhall @@ -0,0 +1,5 @@ +let upstream = + https://github.com/purescript/package-sets/releases/download/psc-0.15.4-20220808/packages.dhall + sha256:60eee64b04ca0013fae3e02a69fc3b176105c6baa2f31865c67cd5f881a412fd + +in upstream diff --git a/client/public/css/flare.css b/client/public/css/flare.css new file mode 100644 index 00000000..c512eaff --- /dev/null +++ b/client/public/css/flare.css @@ -0,0 +1,207 @@ +/*! normalize.css v3.0.3 | MIT License | github.com/necolas/normalize.css */html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,hgroup,main,menu,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block;vertical-align:baseline}audio:not([controls]){display:none;height:0}[hidden],template{display:none}a{background-color:transparent}a:active,a:hover{outline:0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:bold}dfn{font-style:italic}h1{font-size:2em;margin:.67em 0}mark{background:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-0.5em}sub{bottom:-0.25em}img{border:0}svg:not(:root){overflow:hidden}figure{margin:1em 40px}hr{box-sizing:content-box;height:0}pre{overflow:auto}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}button,input,optgroup,select,textarea{color:inherit;font:inherit;margin:0}button{overflow:visible}button,select{text-transform:none}button,html input[type="button"],input[type="reset"],input[type="submit"]{-webkit-appearance:button;cursor:pointer}button[disabled],html input[disabled]{cursor:default}button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0}input{line-height:normal}input[type="checkbox"],input[type="radio"]{box-sizing:border-box;padding:0}input[type="number"]::-webkit-inner-spin-button,input[type="number"]::-webkit-outer-spin-button{height:auto}input[type="search"]{-webkit-appearance:textfield;box-sizing:content-box}input[type="search"]::-webkit-search-cancel-button,input[type="search"]::-webkit-search-decoration{-webkit-appearance:none}fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}legend{border:0;padding:0}textarea{overflow:auto}optgroup{font-weight:bold}table{border-collapse:collapse;border-spacing:0}td,th{padding:0} + +@import url(https://fonts.googleapis.com/css?family=Source+Code+Pro:400,700|Roboto:400,700); + +body { + margin: 20px; +} + +body, p, input, label, legend, h1, h2, h3, h4 { + font-family: 'Roboto', sans-serif; +} + +a, a:visited, a:active, a:hover { + color: #cc0000; +} + +.flare-input > label { + display: inline-block; + width: 150px; +} + +.flare-input { + margin-bottom: 10px; +} + +.flare-input-number { + width: 85px; +} + +input[type="range"] { + width: 150px; + border: 1px solid transparent; +} + +input:invalid { + background-color: #DEAFB4; +} + +label { + font-weight: bold; +} + +fieldset.flare-input-radioGroup { + margin: 0px; + margin-top: 15px; + border: none; + padding: 0px; +} + +.flare-input-radioGroup legend { + padding: 0px; + width: 150px; + float: left; + font-weight: bold; +} + +.flare-input-radioGroup label { + margin-left: 3px; + margin-right: 15px; + cursor: pointer; + font-weight: normal; +} + +code { + background-color: #f0f0f0; + padding-left: 3px; + padding-right: 3px; +} + +.sparkle-test pre, +.sparkle-test code, +.sparkle-test input, +.sparkle-test label, +.sparkle-test legend, +.sparkle-test select, +.sparkle-test textarea { + font-family: 'Source Code Pro', monospace; +} + +fieldset.sparkle-test { + margin-top: 15px; + margin-bottom: 40px; + max-width: 800px; + border: 1px solid #666; + border-radius: 3px; + padding: .35em .625em .75em; +} + +fieldset.sparkle-test > legend { + background-color: #f0f0f0; + border: 1px solid #666; + border-radius: 3px; + float: initial; + width: initial; +} + +.sparkle-test pre { + background-color: #f0f0f0; + padding: 10px; + max-width: 780px; + + /* http://stackoverflow.com/a/248013/704831 */ + white-space: pre-wrap; /* CSS 3 */ + white-space: -moz-pre-wrap; /* Mozilla, since 1999 */ + white-space: -pre-wrap; /* Opera 4-6 */ + white-space: -o-pre-wrap; /* Opera 7 */ + word-wrap: break-word; /* Internet Explorer 5.5+ */ +} + +.sparkle-test .flare-input { + margin-bottom: 5px; +} + +.sparkle-test input:not([type="range"]) { + padding: 3px; + border-radius: 3px; + border: 1px solid #888; +} + +.sparkle-test input:invalid { + background-color: #DEAFB4; +} + +.sparkle-test .flare-input-number, +.sparkle-test .flare-input-int-number { + width: 80px; +} + +.sparkle-test fieldset { + border-radius: 3px; + margin-top: 5px; + margin-bottom: 20px; +} + +.sparkle-test label { + width: 160px; + display: inline-block; +} + +.sparkle-test legend { + padding: 2px 6px; + font-weight: 700; +} + +.sparkle-test .flare-input-list button { + margin-left: 5px; + margin-right: 5px; +} + +.sparkle-test .sparkle-okay { + background-color: #B4DEAF; +} + +.sparkle-test .sparkle-warn { + background-color: #DEAFB4; +} + +.sparkle-string { + color: #E91E63; +} + +.sparkle-number { + color: #1339E8; +} + +.sparkle-boolean { + font-weight: bold; +} + +.sparkle-constructor { + font-weight: bold; +} + +.sparkle-record-field { + font-style: italic; +} + +.sparkle-color { + width: 1em; + height: 1em; + margin-right: 0.5em; + display: inline-block; +} + +.sparkle-tooltip { + cursor: default; +} + +.sparkle-tooltip:hover { + background-color: #f2e7a6; +} + +.sparkle-tooltip > .sparkle-tooltip:hover { + background-color: #e9d563; +} + +.sparkle-tooltip > .sparkle-tooltip > .sparkle-tooltip:hover { + background-color: #dfc220; +} + +.sparkle-tooltip > .sparkle-tooltip > .sparkle-tooltip > .sparkle-tooltip:hover { + background-color: #938015; +} + +.sparkle-tooltip > .sparkle-tooltip > .sparkle-tooltip > .sparkle-tooltip > .sparkle-tooltip:hover { + background-color: #62560e; +} diff --git a/client/public/css/index.css b/client/public/css/index.css new file mode 100644 index 00000000..acd2322f --- /dev/null +++ b/client/public/css/index.css @@ -0,0 +1,313 @@ +/* Page layout */ + +html, body { + height: 100%; +} + +body { + font-family: 'Roboto', sans-serif; + margin: 0; + color: rgb(29, 34, 45); +} + +#wrapper { + display: flex; + flex-direction: column; + height: 100vh; +} + +#body { + display: flex; + flex-direction: column; + flex: 1; +} + +#menu { + background-color: #1d222d; + color: white; + vertical-align: middle; + margin: 0; + padding: 0; +} + + #menu input { + vertical-align: middle; + margin-bottom: 5px; + cursor: pointer; + } + +#home_link { + padding: 0px 10px; + text-decoration: none; + text-align: center; + font-weight: bold; +} + + #home_link > img { + vertical-align: middle; + } + +.menu-item { + list-style: none; + display: inline-block; + border-left: 1px solid #454648; + min-width: 90px; +} + + .menu-item a { + color: white; + text-decoration: none; + } + + .menu-item > label, .menu-item > a > label { + text-align: center; + line-height: 40px; + padding: 0px 10px; + display: block; + } + + .menu-item label { + cursor: pointer; + } + + .menu-item:hover { + background-color: black; + } + + .menu-item input[type="checkbox"] { + display: none; + } + + .menu-item input[type="checkbox"]:checked + label { + background-color: #8490a9; + } + + .menu-item input[type="checkbox"]:not(:checked) + label { + text-decoration: line-through; + color: #ababab; + } + +.menu-dropdown { + position: relative; +} + + .menu-dropdown > label { + display: block; + } + + .menu-dropdown > label:after { + content: ' ▾'; + } + + .menu-dropdown > ul { + position:absolute; + top: 40px; + left: 0px; + min-width: 100%; + display: none; + margin: 0px; + padding: 0px; + background-color: #1d222d; + list-style: none; + z-index: 100000; + } + + .menu-dropdown > ul > li { + margin: 0; + padding: 0; + } + + .menu-dropdown:hover > ul { + display: inherit; + } + + .menu-dropdown li label { + display: block; + padding: 10px 8px; + margin: 0; + } + + .menu-dropdown label:hover { + background-color: black; + } + + .menu-dropdown input[type="radio"] { + display:none; + } + + .menu-dropdown input[type="radio"]:checked + label { + color: #c4953a; + } + + .menu-dropdown a { + display: block; + color: white; + } + + .menu-dropdown a:visited { + color: white; + } + +#editor_view { + display: flex; + flex-direction: row; + flex: 1; + margin-top: 0px; + position: relative; +} + + #editor_view[data-view-mode="output"] #column1 { + display: none; + } + + #editor_view[data-view-mode="code"] #column2_wrapper { + display: none; + } + +#column1, #column2_wrapper { + position: relative; + flex: 1; +} + +#column2_wrapper { + position: relative; + -webkit-overflow-scrolling: touch; + overflow: auto; +} + +#code { + position: absolute; + top: 0; + left: 0; + right: 0; + bottom: 0; + font-size: 13px; +} + +.separator { + flex-basis: 5px; + flex-grow: 0; + flex-shrink: 0; + background-color: rgb(250, 250, 250); +} + +.error { + position: absolute; + z-index: 20; + border-bottom: 2px dotted red; +} + +.warning { + position: absolute; + z-index: 20; + border-bottom: 2px dotted #c4953a; +} + +.ace_gutter-tooltip { + white-space: pre-wrap; +} + +.error-banner { + font-family: 'Roboto Slab', serif; + padding: 10px 20px; +} + +pre { + padding: 20px; + font-family: 'Monaco', monospace; +} + +pre code { + background: none; + border: 0; + margin: 0; + overflow-x: auto; + white-space: pre-wrap; + white-space: -moz-pre-wrap; + white-space: -pre-wrap; + white-space: -o-pre-wrap; + word-wrap: break-word; +} + +iframe { + position: absolute; + left: 0; + right: 0; + width: 100%; + height: 100%; + border: 0; +} + +#loading { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + background: white url(../img/loading.gif); + background-position: center center; + background-repeat: no-repeat; + opacity: 0.85; + z-index: 10000; +} + +#code { + overflow: visible; +} + +.mobile-banner { + background: #dabf8b; + padding: 5px; + border-bottom: 1px solid #1d222d; + font-size: 14px; + margin-bottom: 10px; +} + + +footer { + background-color: #1d222d; + display: flex; + flex-direction: row; + justify-content: center; + gap: 5px; +} + + footer .footer-separator { + color: white; + } + + footer .footer-link { + display: flex; + min-width: 300px; + gap: 2px; + color: white; + } + + footer .footer-link a { + color: white; + } + + footer .footer-link a:visited { + color: white; + } + +@media all and (max-width: 720px) { + .no-mobile { + display: none; + } + + footer { + flex-direction: column; + align-items: center; + } + + footer .footer-link { + min-width: initial; + } +} + +@media all and (min-width: 720px) { + .mobile-only { + display: none; + } +} diff --git a/client/public/css/mathbox.css b/client/public/css/mathbox.css new file mode 100644 index 00000000..dd93e59e --- /dev/null +++ b/client/public/css/mathbox.css @@ -0,0 +1,461 @@ +.shadergraph-graph { + font: 12px sans-serif; + line-height: 25px; + position: relative; +} +.shadergraph-graph:after { + content: ' '; + display: block; + height: 0; + font-size: 0; + clear: both; +} +.shadergraph-graph svg { + pointer-events: none; +} +.shadergraph-clear { + clear: both; +} +.shadergraph-graph svg { + position: absolute; + left: 0; + right: 0; + top: 0; + bottom: 0; + width: auto; + height: auto; +} +.shadergraph-column { + float: left; +} +.shadergraph-node .shadergraph-graph { + float: left; + clear: both; + overflow: visible; +} +.shadergraph-node .shadergraph-graph .shadergraph-node { + margin: 5px 15px 15px; +} +.shadergraph-node { + margin: 5px 15px 25px; + background: rgba(0, 0, 0, .1); + border-radius: 5px; + box-shadow: 0 1px 2px rgba(0, 0, 0, .2), + 0 1px 10px rgba(0, 0, 0, .2); + min-height: 35px; + float: left; + clear: left; + position: relative; +} +.shadergraph-type { + font-weight: bold; +} +.shadergraph-header { + font-weight: bold; + text-align: center; + height: 25px; + background: rgba(0, 0, 0, .3); + text-shadow: 0 1px 2px rgba(0, 0, 0, .25); + color: #fff; + border-top-left-radius: 5px; + border-top-right-radius: 5px; + margin-bottom: 5px; + padding: 0 10px; +} +.shadergraph-outlet div { +} +.shadergraph-outlet-in .shadergraph-name { + margin-right: 7px; +} +.shadergraph-outlet-out .shadergraph-name { + margin-left: 7px; +} + +.shadergraph-name { + margin: 0 4px; +} +.shadergraph-point { + margin: 6px; + width: 11px; + height: 11px; + border-radius: 7.5px; + background: rgba(255, 255, 255, 1); +} +.shadergraph-outlet-in { + float: left; + clear: left; +} +.shadergraph-outlet-in div { + float: left; +} +.shadergraph-outlet-out { + float: right; + clear: right; +} +.shadergraph-outlet-out div { + float: right; +} + +.shadergraph-node-callback { + background: rgba(205, 209, 221, .5); + box-shadow: 0 1px 2px rgba(0, 10, 40, .2), + 0 1px 10px rgba(0, 10, 40, .2); +} +.shadergraph-node-callback > .shadergraph-header { + background: rgba(0, 20, 80, .3); +} +.shadergraph-graph .shadergraph-graph .shadergraph-node-callback { + background: rgba(0, 20, 80, .1); +} + +.shadergraph-node-call { + background: rgba(209, 221, 205, .5); + box-shadow: 0 1px 2px rgba(10, 40, 0, .2), + 0 1px 10px rgba(10, 40, 0, .2); +} +.shadergraph-node-call > .shadergraph-header { + background: rgba(20, 80, 0, .3); +} +.shadergraph-graph .shadergraph-graph .shadergraph-node-call { + background: rgba(20, 80, 0, .1); +} + +.shadergraph-node-isolate { + background: rgba(221, 205, 209, .5); + box-shadow: 0 1px 2px rgba(40, 0, 10, .2), + 0 1px 10px rgba(40, 0, 10, .2); +} +.shadergraph-node-isolate > .shadergraph-header { + background: rgba(80, 0, 20, .3); +} +.shadergraph-graph .shadergraph-graph .shadergraph-node-isolate { + background: rgba(80, 0, 20, .1); +} + +.shadergraph-node.shadergraph-has-code { + cursor: pointer; +} +.shadergraph-node.shadergraph-has-code::before { + position: absolute; + content: ' '; + top: 0; + left: 0; + right: 0; + bottom: 0; + display: none; + border: 2px solid rgba(0, 0, 0, .25); + border-radius: 5px; +} +.shadergraph-node.shadergraph-has-code:hover::before { + display: block; +} +.shadergraph-code { + z-index: 10000; + display: none; + position: absolute; + background: #fff; + color: #000; + white-space: pre; + padding: 10px; + border-radius: 5px; + box-shadow: 0 1px 2px rgba(0, 0, 0, .2), + 0 1px 10px rgba(0, 0, 0, .2); + font-family: monospace; + font-size: 10px; + line-height: 12px; +} + +.shadergraph-overlay { + position: fixed; + top: 50%; + left: 0; + right: 0; + bottom: 0; + background: #fff; + border-top: 1px solid #CCC; +} +.shadergraph-overlay .shadergraph-view { + position: absolute; + left: 0; + top: 0; + right: 0; + bottom: 0; + overflow: auto; +} +.shadergraph-overlay .shadergraph-inside { + width: 4000px; + min-height: 100%; + box-sizing: border-box; +} +.shadergraph-overlay .shadergraph-close { + position: absolute; + top: 5px; + right: 5px; + padding: 4px; + border-radius: 16px; + background: rgba(255,255,255,.3); + color: rgba(0, 0, 0, .3); + cursor: pointer; + font-size: 24px; + line-height: 24px; + width: 24px; + text-align: center; + vertical-align: middle; +} +.shadergraph-overlay .shadergraph-close:hover { + background: rgba(255,255,255,1); + color: rgba(0, 0, 0, 1); +} +.shadergraph-overlay .shadergraph-graph { + padding-top: 10px; + overflow: visible; + min-height: 100%; +} +.shadergraph-overlay span { + display: block; + padding: 5px 15px; + margin: 0; + background: rgba(0, 0, 0, .1); + font-weight: bold; + font-family: sans-serif; +} +.mathbox-loader { + position: absolute; + top: 50%; + left: 50%; + -webkit-transform: translate(-50%, -50%); + transform: translate(-50%, -50%); + padding: 10px; + border-radius: 50%; + background: #fff; +} + +.mathbox-loader.mathbox-exit { + opacity: 0; + -webkit-transition: + opacity .15s ease-in-out; + transition: + opacity .15s ease-in-out; +} + +.mathbox-progress { + height: 10px; + border-radius: 5px; + width: 80px; + margin: 0 auto 20px; + box-shadow: + 1px 1px 1px rgba(255, 255, 255, .2), + 1px -1px 1px rgba(255, 255, 255, .2), + -1px 1px 1px rgba(255, 255, 255, .2), + -1px -1px 1px rgba(255, 255, 255, .2); + background: #ccc; + overflow: hidden; +} + +.mathbox-progress > div { + display: block; + width: 0px; + height: 10px; + background: #888; +} + +.mathbox-logo { + position: relative; + width: 140px; + height: 100px; + margin: 0 auto 10px; + -webkit-perspective: 200px; + perspective: 200px; +} + +.mathbox-logo > div { + position: absolute; + left: 0; + top: 0; + bottom: 0; + right: 0; + -webkit-transform-style: preserve-3d; + transform-style: preserve-3d; +} + +.mathbox-logo > :nth-child(1) { + -webkit-transform: rotateZ(22deg) rotateX(24deg) rotateY(30deg); + transform: rotateZ(22deg) rotateX(24deg) rotateY(30deg); +} + +.mathbox-logo > :nth-child(2) { + -webkit-transform: rotateZ(11deg) rotateX(12deg) rotateY(15deg) scale3d(.6, .6, .6); + transform: rotateZ(11deg) rotateX(12deg) rotateY(15deg) scale3d(.6, .6, .6); +} + +.mathbox-logo > div > div { + position: absolute; + top: 50%; + left: 50%; + margin-left: -100px; + margin-top: -100px; + width: 200px; + height: 200px; + box-sizing: border-box; + border-radius: 50%; +} + +.mathbox-logo > div > :nth-child(1) { + -webkit-transform: scale(0.5, 0.5); + transform: rotateX(30deg) scale(0.5, 0.5); +} + +.mathbox-logo > div > :nth-child(2) { + -webkit-transform: rotateX(90deg) scale(0.42, 0.42); + transform: rotateX(90deg) scale(0.42, 0.42); +} + +.mathbox-logo > div > :nth-child(3) { + -webkit-transform: rotateY(90deg) scale(0.35, 0.35); + transform: rotateY(90deg) scale(0.35, 0.35); +} + +.mathbox-logo > :nth-child(1) > :nth-child(1) { + border: 16px solid #808080; +} +.mathbox-logo > :nth-child(1) > :nth-child(2) { + border: 19px solid #A0A0A0; +} +.mathbox-logo > :nth-child(1) > :nth-child(3) { + border: 23px solid #C0C0C0; +} +.mathbox-logo > :nth-child(2) > :nth-child(1) { + border: 27px solid #808080; +} +.mathbox-logo > :nth-child(2) > :nth-child(2) { + border: 32px solid #A0A0A0; +} +.mathbox-logo > :nth-child(2) > :nth-child(3) { + border: 38px solid #C0C0C0; +} + +.mathbox-splash-blue .mathbox-progress { + background: #def; +} +.mathbox-splash-blue .mathbox-progress > div { + background: #1979e7; +} +.mathbox-splash-blue .mathbox-logo > :nth-child(1) > :nth-child(1) { + border-color: #1979e7; +} +.mathbox-splash-blue .mathbox-logo > :nth-child(1) > :nth-child(2) { + border-color: #33b0ff; +} +.mathbox-splash-blue .mathbox-logo > :nth-child(1) > :nth-child(3) { + border-color: #75eaff; +} +.mathbox-splash-blue .mathbox-logo > :nth-child(2) > :nth-child(1) { + border-color: #18487F; +} +.mathbox-splash-blue .mathbox-logo > :nth-child(2) > :nth-child(2) { + border-color: #33b0ff; +} +.mathbox-splash-blue .mathbox-logo > :nth-child(2) > :nth-child(3) { + border-color: #75eaff; +} + + + + +.mathbox-overlays { + position: absolute; + left: 0; + top: 0; + right: 0; + bottom: 0; + pointer-events: none; + transform-style: preserve-3d; + overflow: hidden; +} +.mathbox-overlays > div { + transform-style: preserve-3d; +} +.mathbox-overlay > div { + position: absolute; + will-change: transform, opacity; +} +.mathbox-label { + font-family: sans-serif; +} +.mathbox-outline-1 { + text-shadow: + -1px -1px 0px rgb(255, 255, 255), + 1px 1px 0px rgb(255, 255, 255), + -1px 1px 0px rgb(255, 255, 255), + 1px -1px 0px rgb(255, 255, 255), + 1px 0px 1px rgb(255, 255, 255), + -1px 0px 1px rgb(255, 255, 255), + 0px -1px 1px rgb(255, 255, 255), + 0px 1px 1px rgb(255, 255, 255); +} +.mathbox-outline-2 { + text-shadow: + 0px -2px 0px rgb(255, 255, 255), + 0px 2px 0px rgb(255, 255, 255), + -2px 0px 0px rgb(255, 255, 255), + 2px 0px 0px rgb(255, 255, 255), + -1px -2px 0px rgb(255, 255, 255), + -2px -1px 0px rgb(255, 255, 255), + -1px 2px 0px rgb(255, 255, 255), + -2px 1px 0px rgb(255, 255, 255), + 1px 2px 0px rgb(255, 255, 255), + 2px 1px 0px rgb(255, 255, 255), + 1px -2px 0px rgb(255, 255, 255), + 2px -1px 0px rgb(255, 255, 255); +} +.mathbox-outline-3 { + text-shadow: + 3px 0px 0px rgb(255, 255, 255), + -3px 0px 0px rgb(255, 255, 255), + 0px 3px 0px rgb(255, 255, 255), + 0px -3px 0px rgb(255, 255, 255), + + -2px -2px 0px rgb(255, 255, 255), + -2px 2px 0px rgb(255, 255, 255), + 2px 2px 0px rgb(255, 255, 255), + 2px -2px 0px rgb(255, 255, 255), + + -1px -2px 1px rgb(255, 255, 255), + -2px -1px 1px rgb(255, 255, 255), + -1px 2px 1px rgb(255, 255, 255), + -2px 1px 1px rgb(255, 255, 255), + 1px 2px 1px rgb(255, 255, 255), + 2px 1px 1px rgb(255, 255, 255), + 1px -2px 1px rgb(255, 255, 255), + 2px -1px 1px rgb(255, 255, 255); +} +.mathbox-outline-4 { + text-shadow: + 4px 0px 0px rgb(255, 255, 255), + -4px 0px 0px rgb(255, 255, 255), + 0px 4px 0px rgb(255, 255, 255), + 0px -4px 0px rgb(255, 255, 255), + + -3px -2px 0px rgb(255, 255, 255), + -3px 2px 0px rgb(255, 255, 255), + 3px 2px 0px rgb(255, 255, 255), + 3px -2px 0px rgb(255, 255, 255), + + -2px -3px 0px rgb(255, 255, 255), + -2px 3px 0px rgb(255, 255, 255), + 2px 3px 0px rgb(255, 255, 255), + 2px -3px 0px rgb(255, 255, 255), + + -1px -2px 1px rgb(255, 255, 255), + -2px -1px 1px rgb(255, 255, 255), + -1px 2px 1px rgb(255, 255, 255), + -2px 1px 1px rgb(255, 255, 255), + 1px 2px 1px rgb(255, 255, 255), + 2px 1px 1px rgb(255, 255, 255), + 1px -2px 1px rgb(255, 255, 255), + 2px -1px 1px rgb(255, 255, 255); + +} +.mathbox-outline-fill, .mathbox-outline-fill * { + color: #fff !important; +} diff --git a/client/public/css/slides.css b/client/public/css/slides.css new file mode 100644 index 00000000..4d10df95 --- /dev/null +++ b/client/public/css/slides.css @@ -0,0 +1,99 @@ + +body { + margin: 0 auto; + -webkit-font-smoothing: antialiased; + font-size: 2vw; + color: #000; + line-height: 1.5em; +} + +pre { + font-size: 1.5vw !important; + line-height: 1.2em; +} + +h1 { + font-size: 3.5vw; +} + +h2 { + font-size: 3vw; +} + +h3 { + font-size: 1.5em +} + +img { + max-width: 100%; +} + +.flexbox { + margin: 5px; + + display: -webkit-box; + display: -moz-box; + display: -ms-flexbox; + display: -webkit-flex; + display: flex; + + flex-flow: row wrap; +} + + +.slide { + width: 80%; + height: 80%; + margin: auto; + display: flex; + justify-content: space-around; + align-items: center; +} + +.title { + display: inline-block; + text-align: center; + margin: auto; +} + +.marwid { + display: inline-block; + margin: auto; +} + +.rowflex { + display: flex; + flex-flow: row wrap; +} + +.colflex { + display: flex; + flex-flow: column wrap; +} + +.block { + display: block; +} + +.padapp { + padding: 0.2vw; +} + +.counter { + margin: 10px; + font-size: initial; +} + +.center { + display: flex; + margin: auto; + justify-content: center; +} + + +.boldEl { + font-weight: bold !important; +} +.italicEl { + font-style: italic !important; +} diff --git a/client/public/css/style.css b/client/public/css/style.css new file mode 100644 index 00000000..9a9d846e --- /dev/null +++ b/client/public/css/style.css @@ -0,0 +1,22 @@ +@import url('https://fonts.googleapis.com/css?family=Roboto|Roboto+Slab'); + +body +{ + font-family: 'Roboto', sans-serif; + color: #404040; +} + +h1, h2, h3, h4, h5, h6 { + font-family: 'Roboto Slab', sans-serif; + color: #1d222d; +} + +a, a:visited, a:active, a:hover { + color: #c4953a; +} + +pre { + background-color: rgb(240, 240, 240); + padding: 10px; + border-radius: 10px; +} diff --git a/client/public/frame.html b/client/public/frame.html new file mode 100644 index 00000000..7a5f8d59 --- /dev/null +++ b/client/public/frame.html @@ -0,0 +1,43 @@ + + + + Try PureScript! + + + + + + + + + + + + + + +
+
+ + diff --git a/client/public/img/favicon-black.ico b/client/public/img/favicon-black.ico new file mode 100644 index 00000000..f4cbbbd3 Binary files /dev/null and b/client/public/img/favicon-black.ico differ diff --git a/client/public/img/favicon-black.svg b/client/public/img/favicon-black.svg new file mode 100644 index 00000000..c8f3f7ea --- /dev/null +++ b/client/public/img/favicon-black.svg @@ -0,0 +1,67 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/client/public/img/favicon-white.svg b/client/public/img/favicon-white.svg new file mode 100644 index 00000000..fa4aa48c --- /dev/null +++ b/client/public/img/favicon-white.svg @@ -0,0 +1,67 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/client/public/img/loading.gif b/client/public/img/loading.gif new file mode 100644 index 00000000..750180e6 Binary files /dev/null and b/client/public/img/loading.gif differ diff --git a/client/public/index.html b/client/public/index.html new file mode 100644 index 00000000..2cdc56ce --- /dev/null +++ b/client/public/index.html @@ -0,0 +1,24 @@ + + + + Try PureScript! + + + + + + + + + + + + + + + + + + + + diff --git a/client/public/js/frame.js b/client/public/js/frame.js new file mode 100644 index 00000000..2f277b67 --- /dev/null +++ b/client/public/js/frame.js @@ -0,0 +1,30 @@ +(function() { + var parent; + + document.addEventListener("DOMContentLoaded", function() { + window.addEventListener("message", function(event) { + parent = event.source; + parent.postMessage("trypurescript", "*"); + const code = event.data.code; + const scriptEl = document.createElement("script"); + scriptEl.type = "module"; + scriptEl.appendChild(document.createTextNode(code)); + document.body.appendChild(scriptEl); + }, { once: true }); + }, { once: true }); + + document.addEventListener("click", function(event) { + if (parent && event.target.nodeName === "A" && event.target.hostname === "gist.github.com") { + event.preventDefault(); + parent.postMessage({ + gistId: event.target.pathname.split("/").slice(-1)[0] + }, "*"); + } + if (parent && event.target.nodeName === "A" && event.target.hostname === "github.com") { + event.preventDefault(); + parent.postMessage({ + githubId: event.target.pathname + }, "*"); + } + }, false); +})(); diff --git a/client/spago.dhall b/client/spago.dhall new file mode 100644 index 00000000..44a9bbdf --- /dev/null +++ b/client/spago.dhall @@ -0,0 +1,45 @@ +{ name = "try-purescript" +, dependencies = + [ "ace" + , "aff" + , "affjax" + , "affjax-web" + , "argonaut-codecs" + , "argonaut-core" + , "arrays" + , "assert" + , "bifunctors" + , "console" + , "control" + , "datetime" + , "effect" + , "either" + , "exceptions" + , "foldable-traversable" + , "foreign-object" + , "functions" + , "functors" + , "halogen" + , "halogen-subscriptions" + , "integers" + , "js-timers" + , "js-uri" + , "lists" + , "maybe" + , "newtype" + , "node-buffer" + , "node-fs" + , "nullable" + , "partial" + , "prelude" + , "random" + , "refs" + , "strings" + , "transformers" + , "tuples" + , "unsafe-coerce" + , "web-html" + ] +, packages = ./packages.dhall +, sources = [ "src/**/*.purs", "test/**/*.purs" ] +} diff --git a/client/src/Main.purs b/client/src/Main.purs new file mode 100644 index 00000000..2ba63761 --- /dev/null +++ b/client/src/Main.purs @@ -0,0 +1,14 @@ +module Main where + +import Prelude + +import Effect (Effect) +import Effect.Aff (launchAff_) +import Halogen.Aff as HA +import Halogen.VDom.Driver (runUI) +import Try.Container as Container + +main :: Effect Unit +main = void $ launchAff_ do + body <- HA.awaitBody + void $ runUI Container.component unit body diff --git a/client/src/Try/API.purs b/client/src/Try/API.purs new file mode 100644 index 00000000..4de89e3d --- /dev/null +++ b/client/src/Try/API.purs @@ -0,0 +1,112 @@ +module Try.API + ( ErrorPosition(..) + , CompilerError(..) + , CompileError(..) + , CompileWarning(..) + , Suggestion(..) + , SuccessResult(..) + , FailedResult(..) + , CompileResult(..) + , get + , compile + ) where + +import Prelude + +import Affjax (URL, printError) +import Affjax.RequestBody as AXRB +import Affjax.ResponseFormat as AXRF +import Affjax.StatusCode (StatusCode(..)) +import Affjax.Web as AX +import Control.Alt ((<|>)) +import Control.Monad.Except (ExceptT(..)) +import Data.Argonaut.Decode (class DecodeJson, JsonDecodeError(..), decodeJson, printJsonDecodeError, (.:)) +import Data.Argonaut.Encode (encodeJson) +import Data.Bifunctor (lmap) +import Data.Either (Either(..)) +import Data.Maybe (Maybe(..)) +import Data.Traversable (traverse) +import Effect.Aff (Aff) +import Effect.Aff.Class (class MonadAff, liftAff) + +-- | The range of text associated with an error +type ErrorPosition = + { startLine :: Int + , endLine :: Int + , startColumn :: Int + , endColumn :: Int + } + +type CompilerError = + { message :: String + , position :: Maybe ErrorPosition + } + +-- | An error reported from the compile API. +data CompileError + = CompilerErrors (Array CompilerError) + | OtherError String + +instance decodeJsonCompileError :: DecodeJson CompileError where + decodeJson = decodeJson >=> \obj -> do + contents <- obj .: "contents" + obj .: "tag" >>= case _ of + "OtherError" -> + map OtherError $ decodeJson contents + "CompilerErrors" -> + map CompilerErrors $ traverse decodeJson =<< decodeJson contents + j -> + Left $ AtKey "tag" $ UnexpectedValue $ encodeJson $ "- Expected a value of `OtherError` or `CompilerErrors` but got '" <> j <> "'" + +type Suggestion = + { replacement :: String + , replaceRange :: Maybe ErrorPosition + } + +type CompileWarning = + { errorCode :: String + , message :: String + , position :: Maybe ErrorPosition + , suggestion :: Maybe Suggestion + } + +type SuccessResult = + { js :: String + , warnings :: Maybe (Array CompileWarning) + } + +type FailedResult = + { error :: CompileError + } + +-- | The result of calling the compile API. +data CompileResult + = CompileSuccess SuccessResult + | CompileFailed FailedResult + +-- | Parse the result from the compile API and verify it +instance decodeJsonCompileResult :: DecodeJson CompileResult where + decodeJson json = + map CompileSuccess (decodeJson json) + <|> map CompileFailed (decodeJson json) + +get :: URL -> ExceptT String Aff String +get url = ExceptT $ AX.get AXRF.string url >>= case _ of + Left e -> + pure $ Left $ printError e + Right { status } | status >= StatusCode 400 -> + pure $ Left $ "Received error status code: " <> show status + Right { body } -> + pure $ Right body + +-- | POST the specified code to the Try PureScript API, and wait for a response. +compile :: forall m. MonadAff m => String -> String -> ExceptT String m (Either String CompileResult) +compile endpoint code = ExceptT $ liftAff $ AX.post AXRF.json (endpoint <> "/compile") requestBody >>= case _ of + Left e -> + pure $ Left $ printError e + Right { status } | status >= StatusCode 400 -> + pure $ Left $ "Received error status code: " <> show status + Right { body } -> + pure $ Right $ lmap printJsonDecodeError $ decodeJson body + where + requestBody = Just $ AXRB.string code diff --git a/client/src/Try/Container.js b/client/src/Try/Container.js new file mode 100644 index 00000000..bc558045 --- /dev/null +++ b/client/src/Try/Container.js @@ -0,0 +1,70 @@ +$.ajaxSetup({ + dataType: "text", +}); + +export function teardownIFrame() { + var $ctr = $("iframe#output-iframe"); + $ctr.remove() +} + +export function setupIFrame(data, loadCb, failCb) { + var $ctr = $("#column2"); + var $iframe = $( + '