# Tailoring (!?) themes when using Hugo modules

**URL:** <https://discourse.gohugo.io/t/tailoring-themes-when-using-hugo-modules/48980>\
**Category:** Using Themes\
**Tags:** modules\
**Created:** [March 22, 2024, 10:35pm UTC](https://discourse.gohugo.io/t/tailoring-themes-when-using-hugo-modules/48980 "2024-03-22T22:35:41Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![DazWilkin](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/dazwilkin/32/9526_2.png) [@DazWilkin](https://discourse.gohugo.io/u/DazWilkin)\
**Post date:** [March 22, 2024, 10:35pm UTC](https://discourse.gohugo.io/t/tailoring-themes-when-using-hugo-modules/48980/1 "2024-03-22T22:35:41Z")

</div>

I’m using a [Module for a theme](https://gohugo.io/hugo-modules/use-modules/#use-a-module-for-a-theme) (I think of this as using a “Theme as a module” but … !?)

```TOML
[module]
  [[module.imports]]
    path = "github.com/onweru/newsroom"

```

The author of the theme [responded to an issue](https://github.com/onweru/newsroom/issues/67#issuecomment-2014553380) to help me understand how to tweak the theme to use a non-italic font. This involves revising `assets/sass/_nav.sass`.

I naively assumed I could create a local copy of this hierarchy with the revised file:

```auto
.
├── assets
│ └── sass
│ └── _nav.sass
├── content
│ └── posts
├── go.mod
├── go.sum
├── hugo.toml
├── public
├── resources
├── static
└── themes

```

But that doesn’t work.

Am I correct in thinking that the correct solution is to [vendor the module](https://gohugo.io/hugo-modules/use-modules/#vendor-your-modules) for the theme and edit it in the vendored (`_vendor`) folder?

I’m confused in part because, to configure [GoatCounter](https://www.goatcounter.com/) for my sites, I’ve been (verifiably) able to create `layouts/_default/baseof.html` and `layouts/partials/analytics.html` as a way to override the theme’s settings (!).

I assumed this was a general merge capability of, if the file exists in the parent (!?) site (!?) module, then it overrides module files.

Thanks in advance!

---

<div class="post-metadata">

**Author:** ![jmooring](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/jmooring/32/4214_2.png) [@jmooring](https://discourse.gohugo.io/u/jmooring)\
**Post date:** [March 22, 2024, 10:51pm UTC](https://discourse.gohugo.io/t/tailoring-themes-when-using-hugo-modules/48980/2 "2024-03-22T22:51:43Z")

</div>

I am able to modify assets/sass/\_nav.sass without vendoring the theme… works fine.

---

<div class="post-metadata">

**Author:** ![DazWilkin](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/dazwilkin/32/9526_2.png) [@DazWilkin](https://discourse.gohugo.io/u/DazWilkin)\
**Post date:** [March 22, 2024, 11:10pm UTC](https://discourse.gohugo.io/t/tailoring-themes-when-using-hugo-modules/48980/3 "2024-03-22T23:10:11Z")

</div>

Hmmm… I must have made a mistake. I’ll try it again.

---

<div class="post-metadata">

**Author:** ![DazWilkin](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/dazwilkin/32/9526_2.png) [@DazWilkin](https://discourse.gohugo.io/u/DazWilkin)\
**Post date:** [March 22, 2024, 11:14pm UTC](https://discourse.gohugo.io/t/tailoring-themes-when-using-hugo-modules/48980/4 "2024-03-22T23:14:08Z")

</div>

My apologies!

Yes, it worked for me too when I retried it; I don’t know what I did wrong earlier.

Sorry to have wasted your time.

Thank you!

---

<div class="post-metadata">

**Author:** ![DazWilkin](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/dazwilkin/32/9526_2.png) [@DazWilkin](https://discourse.gohugo.io/u/DazWilkin)\
**Post date:** [March 22, 2024, 11:42pm UTC](https://discourse.gohugo.io/t/tailoring-themes-when-using-hugo-modules/48980/5 "2024-03-22T23:42:59Z")

</div>

I realized my mistake.

I have continuous deployment that builds the site into a container.

I’d forgotten to include `/assets` in the set of folders copied into the `Containerfile`

---

<div class="post-metadata">

**Author:** ![system](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/system/32/1_2.png) [@system](https://discourse.gohugo.io/u/system)\
**Post date:** [March 24, 2024, 11:43pm UTC](https://discourse.gohugo.io/t/tailoring-themes-when-using-hugo-modules/48980/6 "2024-03-24T23:43:46Z")

</div>

Closed on March 24, 2024, 11:43pm UTC

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.
