GithubHelp home page GithubHelp logo

Comments (6)

zwbetz-gh avatar zwbetz-gh commented on July 27, 2024 1

Using your Matomo example, their docs say to insert the relevant JS into the <head> element. So you can override this theme's head partial with your custom changes. Here's how to do that:

(1) Copy file

/your-site/themes/minimal-bootstrap-hugo-theme/layouts/partials/head.html

(2) Paste that file to

/your-site/layouts/partials/head.html

(3) Put the Matomo JS into the new head partial you created. Hugo will then use the new partial when building your site

from minimal-bootstrap-hugo-theme.

zwbetz-gh avatar zwbetz-gh commented on July 27, 2024

Hi @FelixZett.
Google Analytics is already supported. You can see this if you take a look at the example config.toml.

There are many params in that file, but really this is all you'll need in your own config.toml

[params]
  googleAnalytics = "UA-123456789-1"

from minimal-bootstrap-hugo-theme.

FelixZett avatar FelixZett commented on July 27, 2024

Thanks @zwbetz-gh,
please excuse my bad use of google analytics as example. I was refering to analytics services that uses similar methods like google analytics, but not the tool itself.

from minimal-bootstrap-hugo-theme.

zwbetz-gh avatar zwbetz-gh commented on July 27, 2024

Did you have a particular example in mind?

from minimal-bootstrap-hugo-theme.

FelixZett avatar FelixZett commented on July 27, 2024

Sure, Matomo (formerly Piwik) is an open source analytics. The implementation is similar to Google.
https://matomo.org/docs/installation/#install-the-javascript-tracking-tag
Most themes have some kind of layout partial to add analytics.

from minimal-bootstrap-hugo-theme.

FelixZett avatar FelixZett commented on July 27, 2024

Thank you very much. That should do the trick.

from minimal-bootstrap-hugo-theme.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.