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
Fix Issue 17121 - DDoc documentation is out of date #1703
Conversation
|
I'm not sure what you mean with preprocess Ddoc. #1688 suggests to use Ddoc comments but there are no Ddoc comments. If the Ddoc document are but in comments as is, the compiler would evaluate the macros. I'm thinking of if there's some way to escape the whole Ddoc default theme document to be able to render that on the site. |
#1688 allows to evaluate D code and inject arbitrary variables into you the Ddoc template, i.e. it makes proper templates out of the Ddoc files, e.g. on the D site you could do sth. like this: context["DDOC_COMPILER_TEMPLATE"] = "default_ddoc_theme".readText.rescapeDdoc; and then in the Ddoc file:
You can escape it manually as well, but I thought the main point of this issue was to automatically keep the specification in sync? |
Aha, cool. As long as it works 😃. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently this change is not useful, and neither is embedding the entire HTML of the new theme. Probably the best course of action is to link to the file on GitHub. The wording needs change: avoid "current"; avoid "a bit"; link to $(LATEST); remove "enhanced and provides more options for styling".
IMO, the addition of the new DDoc theme was not executed correctly - the default theme should've been left as it was, and the new theme should've been shipped as a separate file that was parsed by default by the compiler, similar to object.d.
How is that different from now? |
I see that the DDoc theme is built into the DMD executable with an |
Close this as superseded by #1805? |
Fine by me. |
Not really sure on the best course of action here. Just dumping the entire file with all its stylesheets feels wrong.
@jacob-carlborg I guess you would like to be able to preprocess DDoc, e.g. #1688?
CC @acehreli