joy-framework / joy

A full stack web framework written in janet
https://joy.swlkr.com
MIT License
537 stars 30 forks source link

Make validate-element errors a bit more clear #84

Closed yumaikas closed 3 years ago

yumaikas commented 3 years ago

So, I've been using joy's html/encode to help get Praxis's html rendering off the ground, and the name must be a keyword error had me spinning my wheels for a few hours, because I thought it was talking about the value of the name attribute.

I've added what I hope are clarifying edits to the validate-element error messages, to help save the next person from getting lost down the same hole I did.

swlkr commented 3 years ago

This is such a good improvement! Thanks!

:shipit:

yumaikas commented 3 years ago

I did deliberately avoid adding dynamic info to the error messages, on the odd chance this error surfaces to a user.