I am using reactstrap to build a sticky footer component like this example but I cannot find a dedicated footer component.
The only other way is to just use html:
<footer> <div> <span>Place sticky footer content here.</span> </div>
</footer>The problem is the above is not picking my .footer class. That is a different problem, but for now I just want to know if there is a better way.
Footer is only defined in Cards
2 Answers
- In React we do not use
classbutclassNameattribute. Normally it'll throw an error. - Your example uses an additional CSS
sticky-footer-navbar.cssfile provide by Bootstrap that is not provide by default with the compiled code. You have to include it by yourself after get it on their source code on Github Sticky Footer Navbar CSS Source Code
You don't need to separate Footer component. Just add div like you're doing in the above code.
p.s. class = className in react.js.