The config files that ship with Congo contain all of the possible settings that the theme recognises. By default, many of these are commented out but you can simply uncomment them to activate or change a specific feature.
Basic configuration #
Before creating any content, there are a few things you should set for a new installation. Starting in the config.toml
file, set the baseURL
and languageCode
parameters. The languageCode
should be set to the main language that you will be using to author your content.
# config/_default/config.toml
baseURL = "https://your_domain.com/"
languageCode = "en"
-
The next step is to configure the language settings. Although Congo supports multilingual setups, for now, just configure the main language.
Locate the languages.en.toml
file in the config folder. If your main language is English you can use this file as is. Otherwise, rename it so that it includes the correct language code in the filename. For example, for French, rename the file to languages.fr.toml
.
Note that the language code in the language config filename should match the languageCode
setting in config.toml
. # config/_default/languages.en.toml
+
The next step is to configure the language settings. Although Congo supports multilingual setups, for now, just configure the main language.
Locate the languages.en.toml
file in the config folder. If your main language is English you can use this file as is. Otherwise, rename it so that it includes the correct language code in the filename. For example, for French, rename the file to languages.fr.toml
.
The language code in the language config filename should match the languageCode
setting in config.toml
. # config/_default/languages.en.toml
title = "My awesome website"
@@ -18,20 +18,24 @@
links = [
{ twitter = "https://twitter.com/username" }
]
-
The [author]
configuration determines how the author information is displayed on the website. The image should be placed in the site’s assets/
folder. Links will be displayed in the order they are listed.
If you need extra detail, further information about each of these configuration options, is covered in the Configuration section.
Colour schemes #
Congo ships with a number of colour schemes out of the box. To change the scheme, simply set the colorScheme
theme parameter. Valid options are congo
(default), avocado
, fire
, ocean
and slate
.
# config/_default/params.toml
+
The [author]
configuration determines how the author information is displayed on the website. The image should be placed in the site’s assets/
folder. Links will be displayed in the order they are listed.
If you need extra detail, further information about each of these configuration options, is covered in the Configuration section.
Colour schemes #
Congo ships with a number of colour schemes out of the box. To change the scheme, simply set the colorScheme
theme parameter. Valid options are congo
(default), avocado
, cherry
, fire
, ocean
, sapphire
and slate
.
The colourScheme
value should be provided in lowercase. # config/_default/params.toml
colorScheme = "congo"
-
Congo defines a three-colour palette that is used throughout the theme. Each main colour contains ten shades which are based upon the colours that are included in Tailwind.
Congo (default) #
-
-
Avocado #
-
-
Fire #
-
-
Ocean #
-
-
Slate #
-
-
Although these are the default schemes, you can also create your own. Refer to the Advanced Customisation section for details.
Organising content #
By default, Congo doesn’t force you to use a particular content type. In doing so you are free to define your content as you wish. You might prefer pages for a static site, posts for a blog, or projects for a portfolio.
Directory structure #
Here’s a quick overview of a basic Congo project. All content is placed within the content
folder:
Congo defines a three-colour palette that is used throughout the theme. Each main colour contains ten shades which are based upon the colours that are included in Tailwind.
Congo (default) #
+
+
Avocado #
+
+
Cherry #
+
+
Fire #
+
+
Ocean #
+
+
Sapphire #
+
+
Slate #
+
+
Although these are the default schemes, you can also create your own. Refer to the Advanced Customisation section for details.
Organising content #
By default, Congo doesn’t force you to use a particular content type. In doing so you are free to define your content as you wish. You might prefer pages for a static site, posts for a blog, or projects for a portfolio.
Directory structure #
Here’s a quick overview of a basic Congo project. All content is placed within the content
folder:
.
├── assets
│ └── img
│ └── author.jpg
@@ -56,13 +60,13 @@
├── cover.jpg
├── index.md
└── thumb.jpg
-
The thumb
image is used as the article thumbnail and will be displayed in article lists, and the cover
image will be displayed at the top of the article content on individual article pages.
In order to provide maximum performance, thumbnail images are automatically cropped and resized to a 4:3 ratio. Cover images will be automatically resized to fit their content, but any ratio is permitted. The feature
image is a special type, and when present, it will be used in place of both the thumb
and cover
images. Feature images are also present in the article metadata, which is included when content is shared to third-party networks like Facebook and Twitter.
The theme will intelligently detect article images and automatically add them to your site. You don’t have to refer to them in the front matter and simply need to place an appropriately named file within the page resources. If the term feature
, cover
or thumb
is found anywhere in the image filename, then it will be used for that purpose.
The Samples section provides a number of examples of these images (and you can view the source code to see the file structure).
Taxonomies #
Congo is also flexible when it comes to taxonomies. Some people prefer to use tags and categories to group their content, others prefer to use topics.
Hugo defaults to using posts, tags and categories out of the box and this will work fine if that’s what you want. If you wish to customise this, however, you can do so by creating a taxonomies.toml
configuration file:
# config/_default/taxonomies.toml
+/congo/docs/getting-started/article-screenshot_hua3d13341519c77890d7321a79f2cdac7_45153_1320x0_resize_q75_box.jpg 2x" src=/congo/docs/getting-started/article-screenshot_hua3d13341519c77890d7321a79f2cdac7_45153_660x0_resize_q75_box.jpg alt="A screenshot of an article with a thumbnail image">This example shows an article with a thumbnail image.In order to provide maximum performance, thumbnail images are automatically cropped and resized to a 4:3 ratio. Cover images will be automatically resized to fit their content, but any ratio is permitted. The feature
image is a special type, and when present, it will be used in place of both the thumb
and cover
images. Feature images are also present in the article metadata, which is included when content is shared to third-party networks like Facebook and Twitter.
The theme will intelligently detect article images and automatically add them to your site. You don’t have to refer to them in the front matter and simply need to place an appropriately named file within the page resources. If the term feature
, cover
or thumb
is found anywhere in the image filename, then it will be used for that purpose.
The Samples section provides a number of examples of these images (and you can view the source code to see the file structure).
Taxonomies #
Congo is also flexible when it comes to taxonomies. Some people prefer to use tags and categories to group their content, others prefer to use topics.
Hugo defaults to using posts, tags and categories out of the box and this will work fine if that’s what you want. If you wish to customise this, however, you can do so by creating a taxonomies.toml
configuration file:
# config/_default/taxonomies.toml
topic = "topics"
-
This will replace the default tags and categories with topics. Refer to the Hugo Taxonomy docs for more information on naming taxonomies.
When you create a new taxonomy, you will need to adjust the navigation links on the website to point to the correct sections, which is covered below.
Congo has two menus that can be customised to suit the content and layout of your site. The main
menu appears in the site header and the footer
menu appears at the bottom of the page just above the copyright notice.
Both menus are configured in the menus.en.toml
file. Similarly to the languages config file, if you wish to use another language, rename this file and replace en
with the language code you wish to use.
# config/_default/menus.toml
+
This will replace the default tags and categories with topics. Refer to the Hugo Taxonomy docs for more information on naming taxonomies.
When you create a new taxonomy, you will need to adjust the navigation links on the website to point to the correct sections, which is covered below.
Congo has two menus that can be customised to suit the content and layout of your site. The main
menu appears in the site header and the footer
menu appears at the bottom of the page just above the copyright notice.
Both menus are configured in the menus.en.toml
file. Similarly to the languages config file, if you wish to use another language, rename this file and replace en
with the language code you wish to use. Menu links will be sorted from lowest to highest weight
, and then alphabetically by name
.
# config/_default/menus.en.toml
[[main]]
name = "Blog"
@@ -74,13 +78,29 @@
pageRef = "topics"
weight = 20
+[[main]]
+ name = "GitHub"
+ url = "https://github.com/jpanther/congo"
+ weight = 30
+ [main.params]
+ icon = "github"
+ showName = false
+ target = "_blank"
+
+[[main]]
+ identifier = "search"
+ weight = 99
+ [main.params]
+ action = "search"
+ icon = "search"
+
[[footer]]
name = "Privacy"
- url = "https://external-link"
-
The name
parameter specifies the text that is used in the menu link. You can also optionally provide a title
which fills the HTML title attribute for the link.
The pageRef
parameter allows you to easily reference Hugo content pages and taxonomies. It is the quickest way to configure the menu as you can simply refer to any Hugo content item and it will automatically build the correct link. To link to external URLs, the url
parameter can be used.
Menu links will be sorted from lowest to highest weight
, and then alphabetically by name
.
Both menus are completely optional and can be commented out if not required. Use the template provided in the file as a guide.
Detailed configuration #
The steps above are the bare minimum configuration. If you now run hugo server
you will be presented with a blank Congo website. Detailed configuration is covered in the Configuration section.
© 2023 Congo contributors
Powered by Hugo & Congo
\ No newline at end of file
diff --git a/docs/getting-started/thumb-choose.svg b/docs/getting-started/thumb-choose.svg
new file mode 100644
index 00000000..773169f8
--- /dev/null
+++ b/docs/getting-started/thumb-choose.svg
@@ -0,0 +1 @@
+