ihp-hsx 1.4.0 → 1.4.1
raw patch · 2 files changed
+40/−1 lines, 2 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- Test/IHP/HSX/CustomHsxCases.hs +38/−0
- ihp-hsx.cabal +2/−1
+ Test/IHP/HSX/CustomHsxCases.hs view
@@ -0,0 +1,38 @@+{-|+Module: Test.HSX.CustomHsxCases+Description: Test helpers for HSX tests with custom tags and attributes+-}+module IHP.HSX.CustomHsxCases where++import Test.Hspec+import Prelude+import IHP.HSX.QQ+import qualified Text.Blaze.Renderer.Text as Blaze+import Data.Text+import Language.Haskell.TH.Quote+import IHP.HSX.Parser+import qualified Data.Set as Set++myCustomHsx :: QuasiQuoter+myCustomHsx = customHsx + (HsxSettings { checkMarkup = True+ , additionalTagNames = Set.fromList ["mycustomtag", "anothercustomtag"]+ , additionalAttributeNames = Set.fromList ["my-custom-attr", "anothercustomattr"] + }+ )++myTagsOnlyHsx :: QuasiQuoter+myTagsOnlyHsx = customHsx+ (HsxSettings { checkMarkup = True+ , additionalTagNames = Set.fromList ["mycustomtag", "anothercustomtag"]+ , additionalAttributeNames = Set.fromList []+ }+ )++myAttrsOnlyHsx :: QuasiQuoter+myAttrsOnlyHsx = customHsx+ (HsxSettings { checkMarkup = True+ , additionalTagNames = Set.fromList []+ , additionalAttributeNames = Set.fromList ["my-custom-attr", "anothercustomattr"]+ }+ )
ihp-hsx.cabal view
@@ -1,6 +1,6 @@ cabal-version: 2.2 name: ihp-hsx-version: 1.4.0+version: 1.4.1 synopsis: JSX-like but for Haskell description: JSX-like templating syntax for Haskell license: MIT@@ -97,6 +97,7 @@ other-modules: IHP.HSX.ParserSpec IHP.HSX.QQSpec+ IHP.HSX.CustomHsxCases default-language: Haskell2010 build-depends: base >= 4.17.0 && < 4.20