Global Configuration
-Some apps are not third-party apps, for example scroll-to-top button. You can use it like this:
- -{% embed scroll-to-top %}
-
-
-But this only works for chapter that embeds this app, not for the whole book. Most of cases, you want to use it for the whole book. You can do this by adding scroll-to-top
option to embedify preprocessor in book.toml
file like this:
Some apps allow you to automatically add to every chapter. You can do this by adding app-name = true
to embedify preprocessor in book.toml
file to enable it.
For example:
[preprocessor.embedify]
scroll-to-top = true
-And now scroll-to-top
is the only app that supports global configuration.
++ +💥Attention
+When you do this, you don’t need to add
+{% embed scroll-to-top %}
manually. It will be automatically added it to every chapter. Otherwise, it will be rendered twice.
Now scroll-to-top
is the only app that supports global configuration.