I have a navbar with 3 items spaced with space-between, the one on the left is longer in width than the one on the left, this results in the item in the center being shifted to the right, how can i solve this?

Asked
Active
Viewed 32 times
2 Answers
-1
To center the navbar instead of using space-between do this in your css file:
div#nav{
text-align: center;
}
div#nav ul{
display: inline-block;
}
Jonathan Joshua
- 222
- 1
- 10
-1
To center the links, with space-between and flex you can use justify-content-center and also use margin: auto;
Bhavya Khurana
- 11
- 3