Shpadoinkle-disembodied: Shpadoinkle as a static site.

[ bsd3, library, web ] [ Propose Tags ]

Static site backed SPA applications.


[Skip to Readme]
Versions [faq] 0.0.0.1
Change log CHANGELOG.md
Dependencies base (>=4.12.0 && <4.16), directory, filepath, servant, Shpadoinkle, Shpadoinkle-backend-static, Shpadoinkle-html, Shpadoinkle-router, text (>=1.2.3 && <1.3), unliftio [details]
License BSD-3-Clause
Author Isaac Shapira
Maintainer fresheyeball@protonmail.com
Category Web
Uploaded by fresheyeball at 2021-01-06T20:48:52Z
Distributions NixOS:0.0.0.1
Downloads 15 total (15 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Hackage Matrix CI
Docs uploaded by user
Build status unknown [no reports yet]

Modules

[Index] [Quick Jump]

Downloads

Maintainer's Corner

For package maintainers and hackage trustees


Readme for Shpadoinkle-disembodied-0.0.0.1

[back to package description]

Shpadoinkle Disembodied

Goldwater Haddock BSD-3 built with nix Hackage Hackage Deps Hackage CI

This module provides static site generation tools for Html.

Usage

Lets say you have the following API routes for you SPA application:

type Pages m
  = "about" :> View m Int
  :<|> View m ()

And you have a view for each. You can now produce a SiteSpec mapping these routes to the views.

site :: SiteSpec () (Pages m)
site = about 0 :<|> const home

Which can be written to static pages with writeSite. Each route will become a directory, and each View will become an index.html file in that directory.