Menu with Anchor



Does anyone know how to create a menu that becomes active using anchors?

I have a link with href attribute <a href="#section1">Go to Section1</a>

But i want the link to become active after clicking on the link or scrolling to the anchor from the web browser.

The example anchor i am using is <a id="section1"></a>

Can this be done easily with Semantic UI? I am currently using with react as well.