The fay-text package

[Tags: library, mit]

Text type represented as JavaScript strings for Fay and Data.Text for GHC. Use with OverloadedStrings and RebindableSyntax to have Fay treat string literals as Text.


[Skip to ReadMe]

Properties

Versions0.1.0.0, 0.2.0.0, 0.3, 0.3.0.1, 0.3.0.2, 0.3.1, 0.3.2, 0.3.2.1, 0.3.2.2
Change logCHANGELOG.md
Dependenciesfay (>=0.21.2 && <0.24), fay-base (>=0.19.4 && <0.21), text (<1.3) [details]
LicenseMIT
Copyright2013 Michael Snoyman, Adam Bergmark
AuthorMichael Snoyman, Adam Bergmark
Maintaineradam@bergmark.nl
CategoryData, Fay, Text
Home pagehttps://github.com/faylang/fay-text
Bug trackerhttps://github.com/faylang/fay-text/issues
Source repositoryhead: git clone https://github.com/faylang/fay-text.git
UploadedWed Feb 11 09:44:07 UTC 2015 by AdamBergmark
DistributionsLTSHaskell:0.3.2.2, NixOS:0.3.2.2, Stackage:0.3.2.2
Downloads2816 total (101 in last 30 days)
Votes
0 []
StatusDocs available [build log]
Last success reported on 2015-05-19 [all 2 reports]

Modules

[Index]

Downloads

Maintainers' corner

For package maintainers and hackage trustees

Readme for fay-text-0.3.2.2

Changelog

fay-text provides a Text whose values are represented as JavaScript strings for Fay, and as Data.Text for GHC. You can use this package instead of directly depending on text if you want to.

Fay has a special case that's applicable for fay-text. If a file has {-# LANGUAGE OverloadedStrings #-} GHC will replace all string literals with fromString lit. {-# LANGUAGE RebindableSyntax #-} tells GHC to use the fromString currently in scope instead of Data.String.fromString. With these two extensions enabled Fay outputs all string literals as JavaScript strings, which is the same representation as Fay.Text uses.

Note that you can mix modules using text literals and string literals, the behavior is local to the module.