Topic: TypeError: Cannot read property \\\\

Shylmysten free asked 4 years ago

copied in the code from the Full Page Intro with fixed, transparent Navbar It works great when I remove the !this.state.isWideEnough && section of the code but you can\\\'t click on the hamburger menu! How do I fix this?Also, I went into the components and opened NavbarNav.js and deleted the justify-content-around and it is still giving me justify-content-around in my browser. I have tried to clear my cache several times and cannot for the life of me figure out where this is being injected other than the navbarnav.js file in the components folder. thanks!

Mikołaj Smoleński staff answered 4 years ago

To cancel justify-content please update Your code like this:
<Collapse isOpen = { this.state.collapse } navbar>
   <NavbarNav left>
     <NavItem active>
       <NavLink className="nav-link" to="#">Home</NavLink>
       <NavLink className="nav-link" to="#">Features</NavLink>
       <NavLink className="nav-link" to="#">Pricing</NavLink>
       <Dropdown isOpen={this.state.dropdownOpen} toggle={this.toggle}>
         <DropdownToggle nav caret>Dropdown</DropdownToggle>
           <DropdownItem href="#">Action</DropdownItem>
           <DropdownItem href="#">Another Action</DropdownItem>
           <DropdownItem href="#">Something else here</DropdownItem>
           <DropdownItem href="#">Something else here</DropdownItem>
   <form className="form-inline ml-auto">
   <input className="form-control mr-sm-2" type="text" placeholder="Search" aria-label="Search"/>

In this example hamburger should work. Regards

Shylmysten free commented 4 years ago

Thank you very much Sir!!

Please insert min. 20 characters.


Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.



Specification of the issue

  • User: Free
  • Premium support: No
  • Technology: MDB React
  • MDB Version: -
  • Device: -
  • Browser: -
  • OS: -
  • Provided sample code: No
  • Provided link: No