-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrap field/slot references in <var class="field"> #96
Conversation
I like the idea, but ecma-402 uses I would lean towards only recognizing fields whose names match |
Good suggestion. Done. |
Actually, the embedded |
I've pushed up a commit making double-brackets its own type of Node, rather than falling under Format, and marked it more precisely as containing only text, rather than arbitrary other fragments. That seemed more natural to me. If there's some reason the typings you chose are better, let me know; otherwise I'll merge this soon and get it released/upstreamed (as a major version, I guess, since it changes the interpretation of existing text). |
It's a little strange to me that double-brackets have
Great! 👍 |
Unfortunately other format nodes aren't bare text - the parser allows you to put comments and tags inside of certain format nodes. For example, Opened #97 for the more precise types.
Started doing this tonight, but it's more work than I'd realized - ecmarkup re-parses the output of ecmarkdown, and that will need to be updated. |
Got this working on a local branch on top of #97 / tc39/ecmarkup#515. Only remaining issue is that it probably makes more sense not to include the brackets in the parse node, for consistency with other node types. |
In my mind, the brackets in |
be983d3
to
1d2cdde
Compare
That's fair, but I have two reasons for prefering to exclude Anyway, this looks good, and other editors were on board. My only remaining slight hesitation is that at some point I will want to make MOP methods behave like AOs, i.e. make it so that clicking on (We do in a couple cases put invokable things inside of And anyway perhaps instead I'll make it so that hovering over a MOP name (or even a field name?) gives you a little popup that links to the definition. Or something else entirely. I'm fine punting that problem to future me. |
Fixes #95
If/when merged, ecmarkup CSS should be updated to include something like