Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No Permalink field when defining menu.extra #27

Open
cbui opened this issue Jul 14, 2018 · 0 comments
Open

No Permalink field when defining menu.extra #27

cbui opened this issue Jul 14, 2018 · 0 comments

Comments

@cbui
Copy link

cbui commented Jul 14, 2018

I'm getting this error: "theme/partials/header.html" at <.Permalink>: can't evaluate field Permalink in type *hugolib.MenuEntry

When trying to utilize the extra nav:

[[menu.extra]]
    name = "Contact"
    permalink = "something"

Looks like Hugo doesn't support the permalink field?

Switching it in the theme's header.html from

            <a href="{{ .Permalink }}">{{ .Name }}</a>

to

            <a href="{{ .URL }}">{{ .Name }}</a>

to match the main menu nav works.

I'm super new to Hugo so I'm not sure if that's the actual correct fix or not. But if you want a PR for it I can make it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant