Comments (4)
in a navigation bar at the top (like here).
The website code source is at https://github.com/rstudio/bookdown-demo/
The TOC on the top is just some CSS : https://github.com/rstudio/bookdown-demo/blob/main/toc.css
You can probably achieve the same using similar CSS.
from bookdown.
Also if you don't know about it, there is a new project called Quarto that unifies and extends what has been done over the years in the R Markdown ecosystem.
This tool is developed by a team close to R Markdown ecosystem too. it is not a replacement per-se but a lot of improvment has been made and design has been rethought. Especially:
- There is a Book project format: https://quarto.org/docs/books/
- Navigation has been improved and coherence accross layout and format: https://quarto.org/docs/books/book-structure.html
- Feature like you have in tufte has been made generic for all HTML and PDF format - no need for specific function: https://quarto.org/docs/authoring/article-layout.html
Maybe it could be of interest. For R users, it is quite similar to R Markdown.
from bookdown.
I was looking for something more automated. I'm new to HTML so what I say might be total nonsense. Nevertheless, I can create a navigation bar at the top and use it via the in_header
argument, but won't I have to update the contents of the bar manually at the end of the day?
I was putting off diving into Quarto but thanks to you I finally took the plunge. Thank you. :)
from bookdown.
I was looking for something more automated.
We don't have such feature built-in. However, tweaking the generated TOC using CSS to make a different layout is automated, in the sense that if the TOC update, it will be updated.
Nevertheless, I can create a navigation bar at the top and use it via the in_header argument, but won't I have to update the contents of the bar manually at the end of the day?
If you create the navigation bar hard coding the TOC it won't update. Though you could also tweak the templates to insert the TOC where you want, but this is more complex IMO than CSS tweaks.
I was putting off diving into Quarto but thanks to you I finally took the plunge. Thank you. :)
Good! When looking for some specific new things like you do, having a dive into Quarto can be worth it IMO, even for an R user.
from bookdown.
Related Issues (20)
- [FR] Multi language support
- Square brackets around citations in text HOT 2
- Cannot generate pdf via "server" but only html despite I tried probably all suggestions. HOT 4
- Use of 'tab.scap.' for tables? (Non kable() users!) HOT 2
- Hyphenation only works in English HOT 17
- bs4_book - references by chapter not displaying HOT 1
- The manual's recommendation of only previewing the web version is dangerous. HOT 5
- Search in gitbook doesn't work because of empty search_index.json HOT 5
- Check and adapt to new `--number-sections` in Pandoc 3.1.12 HOT 5
- Unnumbered didn't work properly HOT 8
- Section numbering increments on unnumbered sections HOT 2
- [FR] pdf_book compilation: for easier refactoring LaTeX chunks please remove _main.Rmd file HOT 3
- I ran into some problems when using VSCODE to knit RMD HOT 1
- bs4_book error: Error in 1:max_n HOT 6
- "Error in `path_to_connection()`" if one of the files to be compiled has the same name as the final file although in a subfolder HOT 3
- How to write bold but non-Italic Geek letters in bookdown html HOT 5
- bookdown.org is down HOT 3
- Figure numbering is broken in HTML output while using newest RStudio 2024.04.0 with pandoc 3.x
- Figure Caption do not continue in next page
- output_dir in _bookdown.yml is ignored for bookdown::html_document2 HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bookdown.