Navigation Menu

Skip to content

Commit

Permalink
Review feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
George Leslie-Waksman committed Aug 10, 2018
1 parent 6a93712 commit adbc4d6
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 9 deletions.
2 changes: 1 addition & 1 deletion CHANGES.txt
Expand Up @@ -15,7 +15,7 @@ Features
time is specified, the posting time will be displayed alone.
* All built-in themes now support the ``DATE_FANCINESS`` option.
* Theme bundles are now parsed using the configparser module and
can support newlines inside entries as well ad comments
can support newlines inside entries as well as comments

Bugfixes
--------
Expand Down
12 changes: 9 additions & 3 deletions docs/creating-a-theme.rst
Expand Up @@ -813,8 +813,12 @@ Doing the same for layout-reverse, sidebar-overlay and the rest is left as an ex
Bundles
-------

If you have ``webassets`` installed and the ``USE_BUNDLES`` option set to True, Nikola can put several CSS or JS files together in a larger file,
which makes sites load faster. To do that, your theme needs a ``bundles`` file where the syntax is::
If you have ``webassets`` installed and the ``USE_BUNDLES`` option set to True,
Nikola can put several CSS or JS files together in a larger file, which can
makes site load faster for some deployments. To do this, your theme needs
a ``bundles`` file. The file format is a modified
`config <https://docs.python.org/3/library/configparser.html>`_ file with no
defined section; the basic syntax is::

outputfile1.js=
thing1.js,
Expand All @@ -833,7 +837,9 @@ For the Lanyon theme, it should look like this::
code.css,
poole.css,
lanyon.css,
custom.css
custom.css,

**Note:** trailing commas are optional

**Note:** Some themes also support the ``USE_CDN`` option meaning that in some cases it will load one bundle with all CSS and in other will load some CSS files
from a CDN and others from a bundle. This is complicated and probably not worth the effort.
Expand Down
7 changes: 4 additions & 3 deletions docs/theming.rst
Expand Up @@ -73,8 +73,9 @@ parent, engine
older).

bundles
A config file containing a list of files to be turned into bundles using WebAssets.
For example:
A `config <https://docs.python.org/3/library/configparser.html>`_ file
containing a list of files to be turned into bundles using WebAssets. For
example:

.. code:: ini
Expand All @@ -85,7 +86,7 @@ bundles
code.css,
baguetteBox.min.css,
theme.css,
custom.css
custom.css,
This creates a file called "assets/css/all.css" in your output that is the
combination of all the other file paths, relative to the output file.
Expand Down
1 change: 0 additions & 1 deletion nikola/data/symlinked.txt
Expand Up @@ -23,7 +23,6 @@ nikola/data/themes/base/assets/js/html5shiv-printshiv.min.js
nikola/data/themes/base/assets/js/justified-layout.min.js
nikola/data/themes/base/assets/js/moment-with-locales.min.js
nikola/data/themes/base/messages/messages_cz.py
nikola/data/themes/base-jinja/bundles
nikola/data/themes/bootblog4-jinja/assets/css/bootblog.css
nikola/data/themes/bootblog4-jinja/bundles
nikola/data/themes/bootstrap4-jinja/assets/css/bootstrap.min.css
Expand Down
1 change: 0 additions & 1 deletion nikola/data/themes/base-jinja/bundles

This file was deleted.

0 comments on commit adbc4d6

Please sign in to comment.