Skip to content

redesign encoding of dsl element with phantom types #467

Open
malladinagarjuna2 wants to merge 2 commits intoarmanbilge:mainfrom
malladinagarjuna2:dsl
Open

redesign encoding of dsl element with phantom types #467
malladinagarjuna2 wants to merge 2 commits intoarmanbilge:mainfrom
malladinagarjuna2:dsl

Conversation

@malladinagarjuna2
Copy link
Copy Markdown

implements #180

  1. Added phantom type parameter A to HtmlAttr, AriaAttr, and Prop to identify each attribute at the type level
  2. Added ValidAttr[A, E] and ValidProp[A, E] marker typeclasses (which are not variant in E) that gate which attributes can be used on which elements at compile time
  3. Add ElementScopes mapping attributes to their valid element types.
  4. Updated code generators to emit phantom-typed traits and ValidAttr/ValidProp given instances
  5. Preserve source compatibility for aliases like typ and tpe still work
  6. changed tlBaseVersion from 0.2 to 0.3
    used the context of issue 179 and 96

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant