There are two modes to the gallery. You can specify it in the front matter.
content/gallery/anygalleryname/index.md
| |
one-by-one
If you set the mode to one-by-one, you have to set the images front matter. This mode is used to specify captions, order of images.
| |
at-once
If you set the mode to at-once, you don’t need to set the images front-matter. Just put all your images to the static/gallery/anygalleryname folder.
Make a gallery folder under the content folder
root βββ content βΒ Β βββ galleryMake a sub folder under the gallery folder
root βββ content βΒ Β βββ gallery βΒ Β βΒ Β βββ anygallerynameMake a index.md file under the sub folder using this command
hugo new --kind gallery gallery/anygalleryname/index.mdPut your images in static folder
root βββ static βΒ Β βββ gallery βΒ Β βΒ Β βββ anygalleryname βΒ Β βΒ Β β βββ ...your images here