Skip to content

Commit 10c9c4c

Browse files
authored
Make Documentation Updates Easier and More Accurate (#1573)
I made a documentation change and noticed that the result when browsed locally did not quite match what is seen when browsing from the web. After some research, I found mkdocs/mkdocs#2028 That described my situation well and suggested adding an extra javascript script to the configuration. This worked exactly as desired on my local machine. This accounts for the presence of extrajs.js and mkdocs.yml in this request. In addition to the display problem, "mkdocs build" generates the documentation into a directory which is not ignored by git. I added that directory to .gitignore as part of this request. Finally, since I don't know how exactly the documentation makes it to production, I made an insignificant change to one doc file as a sanity check.
1 parent ef3f8f3 commit 10c9c4c

File tree

4 files changed

+11
-1
lines changed

4 files changed

+11
-1
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,6 @@
88
*.project
99
/.settings
1010
/.idea
11+
12+
## mkdocs output
13+
/site

docs/extra/extrajs.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
document.addEventListener("DOMContentLoaded", function() {
2+
document.querySelectorAll("table").forEach(function(table) {
3+
table.classList.add("docutils");
4+
});
5+
});

docs/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ php vendor/phpoffice/phpspreadsheet/samples/Basic/01_Simple.php
8989

9090
## Learn by documentation
9191

92-
For more in-depth documentation, you may read about an [overview of the
92+
For more documentation in depth, you may read about an [overview of the
9393
architecture](./topics/architecture.md),
9494
[creating a spreadsheet](./topics/creating-spreadsheet.md),
9595
[worksheets](./topics/worksheets.md),

mkdocs.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,5 @@ edit_uri: edit/master/docs/
55
theme: readthedocs
66
extra_css:
77
- extra/extra.css
8+
extra_javascript:
9+
- extra/extrajs.js

0 commit comments

Comments
 (0)