Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit fa514fe

Browse files
committed
Add info on how to fix bad brwser loading time for static files
1 parent 3f0d252 commit fa514fe

1 file changed

Lines changed: 22 additions & 2 deletions

File tree

README.md

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,13 +91,33 @@ look like:
9191

9292
### Using Daux to statically generate html files
9393

94-
Assuming the daux.io and VulkanTutorial directories are next to each other, go
95-
into the VulkanTutorial directory and run a command similar to:
94+
Before we generate the static files, we need to tweak daux and the tutorial
95+
setup to prevent it from trying to load a few outside resources (which will
96+
stall your browser when trying to load the otherwise static page)
97+
98+
1. In the `VulkanTutorial` directory, edit `config.json` and remove the
99+
`google_analytics` line so daux doesn't try to load that.
100+
2. In the `daux.io` directory, edit `themes/daux/config.json` and remove the
101+
`font` line so that daux doesn't try to load an external font.
102+
3. In the `daux.io` directory, edit `templates/content.php` and remove the
103+
`<script>` block at the bottom that contains `disqus_config`
104+
4. Rebuild daux according to the earlier instructions so it picks up the
105+
template and theme changes.
106+
107+
We're working on improvements so in the future the above steps won't be
108+
necessary.
109+
110+
Now with the above done, we can generate the static files. Asuming the daux.io
111+
and VulkanTutorial directories are next to each other, go into the
112+
VulkanTutorial directory and run a command similar to:
96113
`php ../daux.io/generate -s . -d out`.
97114

98115
It should genenerate all of the documentation into the `out` directory. The `-s`
99116
option tells Daux the source material is in the current directory.
100117

118+
Note: if you want to generate the docs again, delete the `out` directory first
119+
or daux will make a new `out` directory within the existing `out` directory.
120+
101121
License
102122
-------
103123

0 commit comments

Comments
 (0)