• Stars
    star
    667
  • Rank 67,625 (Top 2 %)
  • Language
    HTML
  • License
    Apache License 2.0
  • Created over 7 years ago
  • Updated 3 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Minimal, single page, smooth-scrolling theme for Hugo static site generator.

Introduction theme for Hugo

Netlify Status Test Hugo versions Latest Release

Introduction is a minimalist, highly-versatile theme for Hugo. It can be configured as a single page, or as a full-featured site with multiple sections. It is multilingual, responsive, and includes a light and dark theme.

New to the Hugo static site generator? Learn the fundamentals here.

Device mockups

Features:

  • Multilingual - supports side-by-side content in different language versions
  • Custom index page sections from Markdown files
  • Projects and Blog sections
  • Page load fade-in CSS effect and smooth scrolling to anchor links
  • Straightforward customization via config.toml
  • Styled Markdown throughout, including post titles
  • Syntax highlighting

Developer-friendly:

  • Sass files included with instant compiling to CSS thanks to Hugo Pipes and PostCSS
  • Thoughtful use of Sass variables makes creating new colour schemes easy

Getting started

Requires the extended version of Hugo. You can find installation instructions here (latest version recommended). Here's a handy Bash function for downloading a specific Hugo version.

To make changes to the theme CSS, extended Hugo's PostCSS requires JavaScript packages to compile the styles. You'll need postcss, postcss-cli, and autoprefixer. Install these globally with npm.

npm i -g postcss postcss-cli autoprefixer

Learn how to install and use npm here.

Note: If you are using Hugo as a snap app, the above Node.js packages have to be installed locally inside exampleSite.

cd exampleSite/
npm i postcss postcss-cli autoprefixer

If you see an error message like:

Error: Error building site: POSTCSS: failed to transform "css/main.css" (text/css): resource "sass/sass/style..." not found in file cache

See issue #210 for more information.

Get the theme

Run from the root of your Hugo site:

git clone https://github.com/victoriadrake/hugo-theme-introduction.git themes/introduction

Alternatively, you can include this repository as a git submodule. This makes it easier to update this theme if you have your Hugo site in git as well:

git submodule add https://github.com/victoriadrake/hugo-theme-introduction.git themes/introduction

Preview the theme

Introduction ships with an fully configured example site. For a quick preview:

cd themes/introduction/exampleSite/
hugo serve  --themesDir ../..

Then visit http://localhost:1313/ in your browser to view the example site.

Add content

The following explains how to add content to your Hugo site. You can find sample content in the exampleSite/ folder.

Introduction section

Create index.md:

hugo new home/index.md

The title frontmatter will be the first large heading.

The content of index.md will be shown as a subtitle line.

You might want to set headless to true in the frontmatter. See headless bundles for more information.

Home page

Content for the home page lives under content/home/. You may add as many files as you want to in markdown format.

Each markdown file will show as a section on the home page and can be ordered by the weight value in the file's frontmatter. You can set image to show an image on the left side of the section. The image file must be in the content/home/ folder.

You may add a contact section by creating contact.md:

hugo new home/contact.md

This will always be shown as the last section on the home page.

Projects section

Introduction provides an easy way to showcase your projects. Each project can even have its own gallery, shown as an image carousel.

Start by creating an index file for the projects section:

hugo new projects/_index.md

Add a title and some optional content to the file. Add an optional weight for ordering projects section.

To create a project, run:

hugo new projects/YourProjectName/index.md

The frontmatter of your new file contains some comments to help your configure your project.

You can set external_link to make the project link to another website.

Add images to your project by placing image files in the YourProjectName/ folder. If you add more then one photo, they will display as a carousel gallery. Images will be ordered by filename. The first image will be shown as the project preview image. You can change the order of your images by adding a weight to that resource's parameters:

resources:
    - src: NameOfYourImage.jpg
      params:
          weight: -100
project_timeframe: "June-December"

You can add a project_timeframe parameter to the frontmatter of your project to optionally display an arbitrary string on the homepage and modal.

Blog section

Create an index file for the blog:

hugo new blog/_index.md

Add an optional weight for ordering blog section on your homepage

Create a new blog post with:

hugo new blog/YourEntryTitle.md

Posts will also display in the Blog section of the home page.

Configure your site

From exampleSite/, copy config.toml to the root folder of your Hugo site and change the fields as you like. Helpful comments are provided.

Multilingual

Introduction currently ships with support for many languages. Contributions for other language translations are welcome.

To create a new language translation, add the .toml file to the i18n/ folder. See the existing files for the necessary fields.

See the hugo documentation for more details.

Menu

Introduction contains a default menu. If you want to override this, you can do so by defining a menu.main in config.toml.

Optionally, you can disable this menu by setting showMenu to false in your config.toml.

Contact section clock

Introduction can optionally show your current local time in your contact section. This uses vanilla JS and variables you provide. You can set this up by copying the settings in the exampleSite config.toml for localTime, timeZone, and timeFormat.

Plausible

You can easily use Plausible.io for analytics by setting plausible = true in your config.toml. Plausible offers a privacy-friendly alternative to Google Analytics. You'll need your own Plausible account - see plausible.io for more.

Google Analytics

Set googleAnalytics in config.toml to activate Hugo's internal Google Analytics template. This supports both Google Analytics 3 (Universal Analytics) and Google Analytics 4. Google Analytics 3 tracking id is of the form 'UA-PROPERTY_ID', and Google Analytics 4 tracking is of the form 'G-MEASUREMENT_ID'.

Disqus

Set disqusshortname in config.toml to activate Hugo's internal Disqus template.

Custom CSS

You can add custom CSS files by placing them under assets/ and adding the paths to the files to the customCSS list in config.toml.

Custom JavaScript

You can add custom JavaScript files by placing them under assets/ and adding the paths to the files to the customJS list in config.toml.

Issues

If you have a question or get stuck, please open an issue for help and to help those who come after you. The more information you can provide, the better!

Contributing

Contributions for new translations, fixes, and features are welcome.

This theme would not be nearly as awesome without its amazing community of open source contributors. Thank you so much! ❀

License

Copyright (C) 2017-2023 Victoria Drake

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

More Repositories

1

hugo-theme-sam

A Simple and Minimalist theme for Hugo with a focus on typography and content.
CSS
417
star
2

dotfiles

Dotfiles and automagic set-up scripts for Linux flavours
Shell
248
star
3

hydra-link-checker

Hydra: a multithreaded site-crawling link checker in Python standard library
Python
121
star
4

kabukicho-vscode

Neon vaporwave dark theme for VS Code. Now with dreamy nostalgia πŸŒ† and hints of hazy liquid synth. 🎧
CSS
94
star
5

django-security-check

Helps you continuously monitor and fix common security vulnerabilities in your Django application.
Shell
88
star
6

neofeed-theme

A personal feed for Neocities, GitHub Pages, or anywhere else, built with Hugo. #IndieWeb friendly and all yours. It's better than Twitter.
HTML
86
star
7

simple-subscribe

Collect emails with a subscription box you can add to any page and build your own independent subscriber base.
Go
82
star
8

i3-linux-config-tokyo-rice

My config files for i3-gaps and Linux, first rice.
74
star
9

hugo-remote

GitHub Action to build and deploy a Hugo site to a remote repository. Deploy from a private repo to a public one!
Shell
66
star
10

link-snitch

:octocat: GitHub Action to scan your site for broken links so you can fix them πŸ”—
Shell
58
star
11

victoriadrake.github.io

🌱 Victoria's autonomous self-improving blockchain-fortified AI static website
HTML
32
star
12

jekyll-cd

:octocat: GitHub Action to build and deploy a Jekyll site to GitHub Pages πŸ§ͺ
Shell
24
star
13

start

A simple and pleasing new tab startpage or homepage.
JavaScript
23
star
14

hugo-theme-quint

Quint: Essence of Minimalism. A theme for Hugo static site generator.
HTML
22
star
15

heartbreak

Unlikes your Twitter Likes. πŸ’”
Go
21
star
16

victoriadrake

πŸ‘‹πŸŒŽ
Go
20
star
17

chatgptmax

Python module to send large input to ChatGPT using preprocessing and chunking.
Python
16
star
18

git-rundown

πŸ—ƒ Check the status of multiple git repositories in a folder
Shell
14
star
19

fancy-unicode

Turn boring plain text into pretty unicode characters.
JavaScript
13
star
20

open-mscs

Based on OMSCS. πŸŽ“ Collaborative open source notes for graduate computer science courses.
13
star
21

hugo-latest-cd

:octocat: GitHub Action to build and deploy πŸš€ a Hugo site to GitHub Pages using latest extended Hugo
Shell
13
star
22

react-in-django

Basic scaffold for a Django Rest Framework + React app.
Python
12
star
23

github-guestbook

A retro 90s website guestbook powered by GitHub Actions
HTML
11
star
24

gitdo

🦾 Tools for doing things with Git repositories
Shell
11
star
25

acme-gallery

Automagical gallery page generator.
JavaScript
7
star
26

django-starter

Django best practices and developer tools in a starter repository for your next project. Clone and start building.
HTML
7
star
27

30-days-of-code

My solutions for HackerRank's 30 Days of Code challenges using Python 3.
Python
7
star
28

hugo-theme-memex

A personal memex theme.
HTML
6
star
29

utc

A UTC clock.
CSS
6
star
30

rss-mailer

A Lambda function for turning your RSS feed items into emails.
Go
6
star
31

xmas

A countdown clock. πŸŽ„
4
star
32

simon

A futuristic, post-apocalypse, AI... Simon game.
JavaScript
4
star
33

standardnotes-to-markdown

Takes a Standard Notes JSON export and creates Markdown files
Python
4
star
34

author-afk

Post tweets with RSS links using AWS Lambda when you're afk.
Go
3
star
35

minimalist-calc

A simple responsive JavaScript calculator. Equivalent capabilities to a very smart monkey doing Grade 6 homework.
HTML
2
star
36

got-issues

A standard-library Python utility that uses the GitHub API to collect issues data from any repository.
Python
2
star
37

.github

πŸ“‚ Default community health files for my account
2
star
38

chicago-api

Capitalize your title in something pretty close to Chicago Manual of Style title case.
TypeScript
2
star
39

vsc-starter-snippets

Visual Studio Code snippets to help you start projects faster.
2
star
40

quint-demo

Demo site for the Hugo theme Quint.
JavaScript
2
star
41

tokyo-life

A demo gallery. Automagically generated with `acme-gallery`.
HTML
2
star
42

pomo-clock

A pomodoro timer.
JavaScript
1
star
43

cats-vs-unicorns

A 90s-inspired tic-tac-toe variant.
JavaScript
1
star