I ran create-react-app and I got the usual structure with public, src and the javascript files. All fine.
Now I want to add Bootstrap3 to this, but I want to add the normal css/js/font folders instead and create my own components that uses Bootstrap.
The question is; where do I put the files?
Inside the public folder, or in the src?
And I assume I simply refer to them the normal way by adding the <script> and the <link> tags in the public/index.html?
Thanks.
This is from create-react-app documentation.
Inside index.html, you can use it like this:
<link rel="shortcut icon" href="%PUBLIC_URL%/favicon.ico">Only files inside the public folder will be accessible by %PUBLIC_URL% prefix
So, you can add your css inside the public folder, and then add it using tag with the url prefix with %PUBLIC_URL%
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With