Configuration

Change the configurations to suit your personal preferences.

The configurations below are the ones recommended and used directly by the Basajan theme.

If you want to change the configuration for Hugo in general, you can visit the official documentation for reference.

title

Title of your site.

Example:

title: "My Awesome Blog"

baseURL

Hostname (and path) to the root.

Example:

baseURL: "https://example.com/"

If you are using a service provider that supports multiple environments, fill this configuration only in your production environment.

languageCode

The language code for your site’s content.

You should only fill in this configuration if your site content is not in English.

To find the correct subtag codes for a language, try the Language Subtag Lookup .

Example:

languageCode: "id"

Optional text that appears in the footer and Hugo’s default RSS template .

If you don’t fill it in, the text that appears in the footer is just a general copyright text.

Example:

copyright: 'Copyright © 2022 · <a href="https://example.com">John Doe</a>'

This configuration also support HTML syntax.

sectionPagesMenu

Section menu for lazy bloggers. This configuration will make all sections a “main” menu item.

To enable this menu, configure sectionPagesMenu in your site config:

sectionPagesMenu: "main"

If you want to add non-content items to the “main” menu, you can do so here.

By default, Basajan uses this configuration. This makes the “home” menu always in front of the other menus, as long as the other menus don’t have a weight less than -1.

menu:
  main:
    - identifier: "home"
      name: "Home"
      pageRef: "/"
      weight: -1

Hugo will automatically merge the above configuration into your site’s configuration if you don’t override it.

author

Author related configuration.

name

Your name as an author.

Example:

author:
  name: "John Doe"

image

The image of your choice that you want to use as your avatar. This image can be in a global or remote resources.

Example:

author:
  image: "img/cover.jpg"

If you prefer to use gravatar , just leave this configuration blank and enter your email configuration instead.

email

The email to be used as the gravatar email and Hugo’s default RSS template.

Example:

author:
  email: "[email protected]"

If you fill in the configuration for the image and email, the avatar that will be displayed by Basajan is the avatar of the image configuration above.

bio

A description of your site, it could be a short biography or whatever. Later this will be displayed on the front page.

Example:

author:
  bio: "Written by John Doe. Just an ordinary guy who likes to write."

social

Configuration related to the author’s social media. Later this will be displayed in the header. All values here are your username.

Example:

author:
  social:
    facebook: "johndoe"
    instagram: "johndoe"
    linkedin: "johndoe"
    twitter: "johndoe"

params

description

Description of your site. This will be a last fallback for every description that should be on every page of your site for meta tags, Open Graph, and Twitter Cards.

Default:

params:
  description: "A very simple & clean blog theme for Hugo, with 0kb JavaScript shipped by default."

image

The image that will be the last fallback for every image that should be on every page of your site for Open Graph and Twitter Cards.

This image can be in a global or remote resources.

Default:

params:
  image: "img/cover.jpg"

credit

Allow Hugo to show the credit in your footer.

Default:

params:
  credit: true

I would really appreciate it if you let the credit appear in your footer. Thank you very much.

paginate

The number of articles that must be displayed in each pagination .

Recommended:

paginate: 8

enableRobotsTXT

Allow Hugo to generate a robots.txt file.

Recommended:

enableRobotsTXT: true

disqusShortname

Activate the Disqus comment system in your article by filling in your Disqus shortname .

Example:

disqusShortname: "your-username"

taxonomies

By default, the Basajan theme has made some changes to Hugo’s built-in taxonomies . This was done to fit the initial concept of Basajan.

taxonomies:
  category: "category"
  tag: "tags"

To apply this configuration, you must configure the taxonomies as follows for Hugo to merge the theme configuration.

taxonomies:
  _merge: "deep"

markup

Basajan has a opinionated syntax highlighting configuration .

markup:
  highlight:
    lineNos: true
    style: "xcode-dark"

If you have no problem with this, you can configure the markup as follows for Hugo to merge the theme configuration.

markup:
  _merge: "deep"

minify

To create a valid website page structure, you have to make some changes to the configuration for minification .

Otherwise, your web page will not pass validation for example by W3C.

minify:
  tdewolff:
    html:
      keepQuotes: true
      keepWhitespace: false

You are highly recommended for configure the minify as follows for Hugo to merge the theme configuration.

minify:
  _merge: "deep"