A library for constructing type-safe and (mostly) spec-compliant HTML.
- For each of global, HTMX, event listeners, arias, and scoped attributes:
- Make constructors for
Attribute
GADT. - Make render functions.
- Modify
ValidElementsFor
. - Modify the attribute selector functions in
HTML.Types.QuerySelector
to take their appropriate types.
- Make constructors for
- Add relevant type class instances (Bounded, Enum, Eq, Ord, Show, etc) and from/to text functions to applicable types.
- Consider a
contenteditable/inputmode
dual attribute type for theSafe
module. - Add safe builder functions for any HTML elements with complex conditions for
its permitted content, such as what was done with
Brigid.HTML.Elements.Safe.Table
. Go through the entire list of elements again to determine what qualifies for this. - Add support for the SVG tag.
- Add support for MathML.
- Look into safely constructing Shadow DOM elements.
- Consider
Default
type class that returns the default value for a given type or attribute. - Review common classes (
Id
,Class
,Name
, etc) and maybe make smart constructors that prevent users from creating them with invalid characters, rather than escaping them after the fact. - Consider writing Aeson instances and Fleece schemas for common types.
- Add support for XML.
- Add function to produce an XML WSDL from a provided Brigid XML structure?
- For each attribute:
- Make constructors for
Attribute
GADT. - Make render functions.
- Modify
ValidElementsFor
.
- Make constructors for
- Add safe builder functions for any HXML elements with complex conditions for its permitted content. Go through the entire list of elements again to determine what qualifies for this.
- Consider
Default
type class that returns the default value for a given type or attribute.
- Change all
ToText
andToBytes
functions to use builders? Export them for use in render, but not fromBrigid.HTML.Types
.