css - React components styling methods -
i have following component -
import react 'react'; import {route, link} 'react-router-dom' import error './error' class navigationbar extends react.component { render() { return ( <div classname="nav"> <nav classname="navbar navbar-inverse bg-inverse"> <ul classname="nav navbar-nav"> <li classname="nav-item"> <link to={"/data"} classname="nav-link"> data </link> </li> <li classname="nav-item"> <link to={"/analysis"} classname="nav-link"> analysis </link> </li> <li classname="nav-item"> <link to={"/monitor"} classname="nav-link"> monitor </link> </li> </ul> </nav> <route path={"/webiks/:user"} component={error}/> </div> ); } } export default navigationbar; in addition added nav.css file index.html in order make changes boostrap styling.
the problem when entering "webkis/:user" url style boostrap styling without changes of nav.css file. if 1 can explaing reason , , mention of common methods styling components (which not inline styling).
thanks.
place nav.css in same folder navigationbar.js, add line on import list: import './nav.css'
Comments
Post a Comment