-
Notifications
You must be signed in to change notification settings - Fork 106
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
Add option to emit separate files for <head> and <body> #14
Comments
Hi @mrspacemankey, We actually have the exact same use case. The problem for us was that beyond having two heads, the CSS from sphinx would clash with the one from bootstrap and from json-schema-for-humans. Even though it is often seen as bad practice, we got the results we wanted with an iframe .. raw:: html
<iframe style="width: 100%; height: 80vh" frameBorder="0" src="./_static/schema_doc.html"></iframe> That being said, I'm open to other ways of outputting the result! |
Hi @dblanchette , I can confirm your case works, and even though I don't like I still tried to solve the problem of the CSS clash of scripts. It is possible to modify the default However, this still causes an issue with CSS. I could solve it by manually re-ordering the items in
Of course, the problem is that the templating engine of I will keep searching for a proper solution to adding the json schema in-line, as it would be very nice for documentation. |
Looking at issue #4, it is connected to this. Replacing JS with CSS would fix this problem I think. It's probably a lot of work though. |
Thanks for the additional information! I just added a comment in #4 about having a version without JS (but also without the collapsible sections). I'll close this one for now. |
So I ran into this along with the other linked issue as I am also looking to include schema documentation in our Sphinx docs. Based on the previous note:
I noticed in #4 that there is now |
I'd just like to add that I have a similar use case, but using |
Thanks for your support so far, I appreciate the effort.
I am working on including the generated HTML files in a documentation generated by
sphinx
(using reST).The problem is,
sphinx
generates a wrapper HTML which already contains<head>
. Since I include the generated HTML as-is, it causes problems since the document now has two heads. However, it is possible to handle adding additional items into this original<head>
section withsphinx
, and it would be easier if separate files were generated for the<head>
and<body>
sections of the output.Adding this might be a feature bloat, or too specific use-case. What do you think? I can also implement a post-processing script that does the separation.
The text was updated successfully, but these errors were encountered: