1

I created a website using react and now I want to include a web URL inside a component I made NavLinks. The code is given below.

`

I have added the part i want to include as the url as a comment.

 `<Nav scrollNav = {scrollNav}>
        <NavbarContainer>
            <NavLogo onClick={toggleHome}>Grama-Check </NavLogo>
            <MobileIcon onClick={toggle}>
              <FaBars/>
            </MobileIcon >
            
               <NavMenu>
              <NavItem> 
                <NavLinks to='about' smooth={true} duration={500} spy={true} exact = 'true' offset={-80}>About</NavLinks>
              </NavItem>
              <NavItem>
                <NavLinks to='services'  smooth={true} duration={500} spy={true} exact = 'true' offset={-80}>Services</NavLinks>
              </NavItem>
              <NavItem>
                <NavLinks to='apply'  smooth={true} duration={500} spy={true} exact = 'true' offset={-80}>Apply</NavLinks>
              </NavItem>  
              {/* <NavItem>
              
                <a href= 'https://gramachecksupport.slack.com'>Help</a>
              </NavItem>    */}

             
              
            </NavMenu>

`

1 Answers1

0

If you work with external URLs, you can try to check this topic "using NavLink with external URL " for answer.

Tatlex
  • 1
  • 3