Flexbox navigation issue

Hello experts,

I have a problem with a flexbox applied to navigation items. Whenever I try to hover some of them (hover effect is bold on anchors), it moves all the navigation items a bit because an anchor tag grows about 2px, which is caused by that bold effect.

How to fixed that? Besides setting some core width to all anchors.
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Brandon LyonSenior Frontend DeveloperCommented:
Your options as I see them:

You don't have to set a width on all anchors, you could set a max-width on the container.
You can change the font in non-bold ways. You could add a dark text shadow instead, or make the font a darker color.
You can change the letter spacing to offset the extra space taken by the bolding.
Use javascript to set the width of the item or container when it's not bolded, and then bold it.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Fajer39Author Commented:
1. and 3. didn't work, I don't know why
2. unfortunately not an option- client's wish...
4. how would you do that without jquery? Project use react.js + flux.
Fajer39Author Commented:
ad 4. jquery can be used but I would be better to handle this problem without JS,
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.