Navigation Menu

Skip to content
This repository has been archived by the owner on Jul 8, 2021. It is now read-only.

Ordering of elements in the main nav menu on the left is still broken #71

Open
chhh opened this issue Jul 6, 2017 · 3 comments
Open

Comments

@chhh
Copy link

chhh commented Jul 6, 2017

There's:

  • date in front matter
  • weight in front matter
  • weight in the config

No matter what I'm changing - the order of elements stays the same in the nav menu.

Using Hugo 0.24.1

@maffelbaffel
Copy link

In my case all menu items are ordered correctly but the first one (which has a weight of 0!)
Have you tried setting the weight of the first menu item from 0 to 1 ?
This seemed to fix the ordering for me.

@chhh
Copy link
Author

chhh commented Jul 22, 2017 via email

@maffelbaffel
Copy link

maffelbaffel commented Jul 22, 2017

I guess its because of this line:
https://github.com/gohugoio/hugo/blob/b2e3748a4e148a9624b9906bd8f34a238a54429c/hugolib/pageSort.go#L63

Dunno why they catch out these Weight == 0 cases.
Edit: See gohugoio/hugo#2673

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

No branches or pull requests

2 participants