Disable smart constructor for now

This commit is contained in:
Nathan McCarty 2025-02-19 05:00:28 -05:00
parent 2929bceaa1
commit 7f4bcf5f51
2 changed files with 16 additions and 16 deletions

View file

@ -5,15 +5,15 @@ import SSG.HTML
import Structures.Dependent.DList import Structures.Dependent.DList
helloWorld : Html "html" helloWorld : Html "html"
helloWorld = -- helloWorld =
tag "html" ["lang" =$ "en"] [ -- tag "html" ["lang" =$ "en"] [] [
tag "head" [] [ -- tag "head" [] [
tag "title" [] "Example" -- tag "title" [] "Example"
], -- ],
tag "body" [] [ -- tag "body" [] [
tag "p" [] [Text "Hello World!"] -- tag "p" [] [Text "Hello World!"]
] -- ]
] -- ]
main : IO () main : IO ()
main = putStr $ render helloWorld main = putStr $ render helloWorld

View file

@ -123,10 +123,10 @@ namespace Html
TagType' : (type : String) -> {auto prf : IsValidTag type} -> Type TagType' : (type : String) -> {auto prf : IsValidTag type} -> Type
TagType' type {prf} = TagType prf TagType' type {prf} = TagType prf
||| Smart constructor for tags -- ||| Smart constructor for tags
public export -- public export
tag : (type : String) -> {auto prf : IsValidTag type} -> TagType prf -- tag : (type : String) -> {auto prf : IsValidTag type} -> TagType prf
tag type {prf = (PVoid type)} = Void type -- tag type {prf = (PVoid type)} = Void type
tag type {prf = (PRawText type)} = RawText type -- tag type {prf = (PRawText type)} = RawText type
tag type {prf = (PEscapableRawText type)} = RawText type -- tag type {prf = (PEscapableRawText type)} = RawText type
tag type {prf = (PNormal type)} = Normal type -- tag type {prf = (PNormal type)} = Normal type