hugo-coder | A minimalist blog theme for hugo | Theme library
kandi X-RAY | hugo-coder Summary
kandi X-RAY | hugo-coder Summary
A simple and clean blog theme for Hugo.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of hugo-coder
hugo-coder Key Features
hugo-coder Examples and Code Snippets
Community Discussions
Trending Discussions on hugo-coder
QUESTION
I'm trying to update my blog which uses the hugo-coder
theme. I've tried updating the submodule that I had added, post the upgrade when I run the hugo server
command, I get the following exception :
ANSWER
Answered 2021-Mar-16 at 05:30Ok, so turns out that I was missing the relevant security policies in my config.toml
file. I referred to the default config.toml file here
The config file should've looked somewhat like this :
QUESTION
- I am currently building a site in Hugo using the theme
Hugo-Coder
avatar.png
is my current avatar specified inconfig.toml
- In
config.toml
you can enable dark mode by adding:colorscheme = "auto"
- This enables dark mode, but my avatar does not show well because it is black
- I need a way to change
avatar.png
toavatarDarkMode.png
based on if the user's system is set to light or dark mode
Hopefully I added enough information!
Source code repo: GitHub Repo
...ANSWER
Answered 2020-Aug-12 at 05:37You might consider a shortcode similar to the one used in onweru/newsroom
:
Picture You want to use darkmode images when darkmode is enabled on a device and a regular image on lightmode? It takes 3 positional parameter
Store these images in the
static/images
directory.
QUESTION
What do you want exactly?
I have a website in Hugo. However I have a peculiar situation.
Scientists and Electrical Engineers and others may have specific needs. For Eg: Having a single page that shows a simulation. Or in my case using webbluetooth and webusb that I have written from scratch in HTML, CSS and JS. Moreover these pages may be generated by custom scripts. So you can have git submodules inside your hugo site that specifically cater to generating these custom, single page html that you just want to add to your website.
So all I want is to have a menu item or sidebar whatever the existing theme supports, but instead of showing the default html, it should show my custom, hard-coded, already ready and prepared html file - which may as well be an index.html
file in a folder with all the necessary contents ready and cooked - something like the _site
folder that jekyll creates.
What do you mean by custom html?
I mean it doesn't take the formatting of the hugo theme. It has its own formatting, but because its just a single page in the whole website its not fruitful to have its own layout written in Hugo or maybe its just worth the effort to do that cause you already have it working using some other technology.
What have you done so far and what works?
I am actually coming from a Jekyll background where it's as simple as changing the layout
frontmatter and making it nil
or even something that doesn't exist at all and jekyll does a great job of showing custom HTML in an existing theme. Tried the same with Hugo but that didn't work.
What are you testing on?
hugo-coder and(or) hugo-academic
Any specific requests?
Ideally I would like to have submodules in my hugo site folder where those submodules generate custom html in known folders and then somehow make a corresponding markdown file in Hugo that is responsible for showing the custom html.
I want to avoid writing the whole html in the markdown itself. But if no other solution is possible then I guess I don't have a choice.
Do let me know if its possible and worthwhile to pursue this and any references that might help.
...ANSWER
Answered 2020-Apr-11 at 10:06So I don't know if this is the perfect solution but it somehow works for the moment. I will not accept it as its not perfect and I am waiting for some of the more experienced folks to answer.
I got something working by doing the following -
- I had a page built using Jekyll. Jekyll builds the site in a folder called
_site
. - I copied the
_site
folder intostatic
folder of Hugo and renamed it correspondingly to CustomHTML OR you could use the flag-d
or declare it in the_config.yml
file :destination:
- Since I am testing it on hugo-acdemic theme, for that I added the following to the
config.toml
file to show it in the menu -
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install hugo-coder
Configure your config.toml. You can either use this minimal configuration as a base, or look for a complete explanation about all configurations here. The config.toml inside the exampleSite is also a good reference.
Build your site with hugo serve and see the result at http://localhost:1313/.
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page