Log in Sign up

Remove website title from browser tab on specific pages?

Is it possible to remove my website title from the browser tab, just on the homepage? I'd just like it to say "Home" without it being followed by the name of my website. Thanks!


2 years ago, 2 replies   developers   Edit question

Yes, this is possible – the title in your browser tab is defined in your template's <head> section, which for the blog template looks like this (line 5):

    <title>{{> title}}</title>

The value of the partial template {{> title}} is in turn passed to each view when rendered through your template's configuration file, package.json:

    "entries.html": {
      "partials": {
        "title": "{{{title}}}",
...

I recognize this is confusing – there are a lot of things (tags, variables, partial templates) called title!

Answered 2 years ago · Edit answer

Thank you so much! I've deleted the

<title>{{> title}}</title>

code, and have now manually added

<head>
    <title>Page Name</title>
</head>

to every main page, and that did the trick!

(Apologies for poor formatting, the code kept disappearing when I posted so this was my workaround).

Answered 2 years ago · Edit answer