Now that our project folder is ready with Hugo’s structure, we intialize it with NPM to download our dependency, just bootstrap for now. This would add a mytheme folder with similar structure as the base folder. Now we create a default theme, although this is optional but helps keep the structure clean. You should see directories: layouts, data, content, archetypes, resources…more on this later. Too good to be true, but Hugo is fast, really fast. This will create a Hugo skeleton site within milliseconds. Hugo needs to be in your environment variables or system path to run, make sure you do that as we will need to run Hugo command very often Open command prompt/shell to navigate into it: Go to a suitable home/project folder on your computer. If you get errors or commands look unfamiliar, you can revert to these versions Initialize project directory We will not cover Git basics in this article, but feel free to read up separately as there are plenty of resources.Īt the time of writing this article, I am using Hugo Static Site Generator v0.79.0-1415EFDC/extended and Bootstrap 5 beta. Used in this article is available on GitHub This is optional, but highly recommended for version control and remote backups. We use this to maintain project depedencies IMPORTANT: make sure you pick the extended version, Hugo_extended_0.xx.x_… OR your favourite code editor for html, css and editing/maintaining the project, vscode is what I will be using throughout the guide You will need the following tools to be downloaded and installed: The tools we will use are cross-platform and should work on Windows, MacOS and Linux. Please make sure you have gone through Part 1įor background and pre-reqs. Starting & configuring your project with Boostrap and Hugo Server If you are experienced with Hugo, you can use then build your own structure and site, alternatively, you can use the project to then import ready made bootstrap templates and adapt those pages to Hugo. This article will help you setup a basic boilerplate project with Hugo Server, a custom theme and Bootstrap 5 loaded.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |