datastar-hs-1.0.1.0: datastar-hs.cabal
cabal-version: 3.0
name: datastar-hs
version: 1.0.1.0
synopsis: Haskell bindings for Datastar
description:
Server-side SDK for building real-time hypermedia applications with
<https://data-star.dev/ Datastar>. Stream HTML fragments, reactive
signal updates, and scripts to the browser over server-sent events
(SSE). Built on WAI so it works with Warp, Scotty, Servant, Yesod,
and any other WAI-compatible framework.
homepage: https://github.com/starfederation/datastar-haskell
bug-reports: https://github.com/starfederation/datastar-haskell/issues
license: MIT
license-file: LICENSE
author: Carlo Hamalainen
maintainer: carlo@carlo-hamalainen.net
category: Web, Hypermedia
build-type: Simple
extra-doc-files: CHANGELOG.md README.md
source-repository head
type: git
location: https://github.com/starfederation/datastar-haskell.git
library
exposed-modules:
Hypermedia.Datastar
Hypermedia.Datastar.Attributes
Hypermedia.Datastar.ExecuteScript
Hypermedia.Datastar.Logger
Hypermedia.Datastar.PatchElements
Hypermedia.Datastar.PatchSignals
Hypermedia.Datastar.Types
Hypermedia.Datastar.WAI
hs-source-dirs: src
default-language: Haskell2010
default-extensions:
ImportQualifiedPost
OverloadedStrings
build-depends:
, base >= 4.14 && < 5
, aeson >= 2.0 && < 3
, bytestring >= 0.10 && < 1
, http-types >= 0.12 && < 1
, text >= 1.2 && < 3
, wai >= 3.2 && < 4
library examples
visibility: public
hs-source-dirs: examples
exposed-modules:
Examples.ActivityFeed
Examples.HeapView
Examples.HelloWorldChannel
Examples.HelloWorldServant
Examples.HelloWorldWarp
default-language: Haskell2010
default-extensions:
ImportQualifiedPost
OverloadedStrings
-- heap-view relies on -O0 so each call to mkSimpleExpr/mkMapExpr/mkFibsExpr
-- allocates fresh thunks instead of being floated to a CAF. The other
-- examples are fine at -O0 too.
ghc-options: -O0
build-depends:
, base >= 4.14 && < 5
, aeson >= 2.0 && < 3
, bytestring >= 0.10 && < 1
, containers >= 0.6 && < 1
, datastar-hs
, ghc-heap >= 9.0 && < 10
, http-media >= 0.8 && < 1
, http-types >= 0.12 && < 1
, servant-server >= 0.19 && < 1
, stm >= 2.4 && < 3
, tagged >= 0.8 && < 1
, text >= 1.2 && < 3
, time >= 1.9 && < 2
, uuid >= 1.3 && < 2
, wai >= 3.2 && < 4
, warp >= 3.2 && < 4
executable e2e-server
hs-source-dirs: e2e-server
main-is: Main.hs
build-depends:
, base
, aeson
, bytestring
, datastar-hs
, http-types
, lucid2
, text
, warp
, wai
default-language: Haskell2010
default-extensions:
DeriveGeneric
DeriveAnyClass
DerivingStrategies
ImportQualifiedPost
OverloadedStrings
ScopedTypeVariables
ghc-options: -threaded
test-suite datastar-hs-test
type: exitcode-stdio-1.0
hs-source-dirs: test
main-is: Main.hs
other-modules:
Hypermedia.Datastar.ExecuteScriptSpec
Hypermedia.Datastar.PatchElementsSpec
Hypermedia.Datastar.PatchSignalsSpec
Hypermedia.Datastar.SSESpec
build-depends:
, base
, bytestring
, datastar-hs
, hspec
, text
, wai
default-language: Haskell2010
default-extensions:
ImportQualifiedPost
OverloadedStrings
executable hello-world-warp
main-is: hello-world-warp.hs
hs-source-dirs: examples/exe
default-language: Haskell2010
build-depends:
, base >= 4.7
, datastar-hs:examples
ghc-options: -threaded
executable hello-world-servant
main-is: hello-world-servant.hs
hs-source-dirs: examples/exe
default-language: Haskell2010
build-depends:
, base >= 4.7
, datastar-hs:examples
ghc-options: -threaded
executable hello-world-channel
main-is: hello-world-channel.hs
hs-source-dirs: examples/exe
default-language: Haskell2010
build-depends:
, base >= 4.7
, datastar-hs:examples
ghc-options: -threaded
executable activity-feed
main-is: activity-feed.hs
hs-source-dirs: examples/exe
default-language: Haskell2010
build-depends:
, base >= 4.7
, datastar-hs:examples
ghc-options: -threaded
executable heap-view
main-is: heap-view.hs
hs-source-dirs: examples/exe
default-language: Haskell2010
build-depends:
, base >= 4.7
, datastar-hs:examples
ghc-options: -threaded -O0