-
Notifications
You must be signed in to change notification settings - Fork 18
Is there a way to specify format:
without putting it in the yml
file?
#29
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
Comments
Yeh this is why I'm completely against it, the file would essentially be unreadable without it |
@chrisjsewell unreadable outside the sphinx site context itself - do you imagine that somebody would want to read one of these files, and understand the "key1 -> key2" mapping, outside of the Sphinx build that the |
To put it from a user's perspective, I think that a Jupyter Book user doesn't care about that |
Unreadable programmatically and would break all CLI functionality. It's basically the same discussion we've had with the coexistence of sphinx.yaml and conf.py |
Users either use the default key mapping, or the |
Could you explain this? What would break if:
? |
I am worried that we are straying from one of the principles of our design here:
So if we stray from that, I wanna make sure we have a strong reason for doing so. |
To quote #28 (comment) explicit is better than implicit |
I'm not talking about jupyter-book build, I'm talking about the cli in this package |
As a Jupyter Book user, is it useful for me to see the Something that might make this |
What? I think you need to read the README again, this is already a format: users have to choose between this or |
Right - it's in the README of this repository but I'm wondering if this is a feature that anybody has requested or discussed before (e.g., is there an issue where we discuss this?). To my knowledge this format doesn't already exist in jupyter-book, it would be introducing something new. I am trying to understand if this is something that users want or need, that should be our driving principle for what we build. |
Yes it does already exist, this is exactly why I added it. |
In a conversation @chrisjsewell pointed out that we basically already have two different kinds of documents defined with Jupyter Book's
And this is a way to explicitly disambiguate them. I think this is a reasonable rationale for adding a |
@choldgraf My thoughts on @chrisjsewell I have seen a I think it is good to have the One aspect of the
this would allow the FWIW - I think we should focus on having a single |
It migrates a current jupyterbook toc to the most suitable format of jb-book or jb-article (see the tests) |
Well that is cool. I'll checkout the tests. |
Yeh and in the jupyterbook PR it checks whether the toc is valid (e.g. if it has not been migrated) and points users towards the migrate command |
and as a concluding point here, a key design principle is that "the toc must be (programatically) readable as a standalone file". |
I like the idea of defining "schemas" that can provide more "reader-facing words" (like "part" and "chapter") which @chrisjsewell added via the
format
key. One challenge with this is that it'll require all Jupyter Book users to add that key to the top of their_toc.yml
file.It seems like another approach could be to allow for people to specify
format
inconf.py
. In this case, Jupyter Book could set this configuration for people, and then they wouldn't have to add this to their TOC layout.One downside of this is that information that defines the
_toc.yml
schema, and the toctree structure itself, would now be in two different places.Curious if @chrisjsewell thought about this, or had strong opinions one way or another. If there aren't strong opinions, perhaps we could allow for
toc_format = "jb-article"
inconf.py
as well?The text was updated successfully, but these errors were encountered: