Archived topic
Bootstrap code is changing the font style of my website
7 replies · Started by SAGAR on August 22, 2022
I have developed a tool that requires a bootstrap code to run properly. But when I use these bootstrap codes
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
they are changing the font style of my site and making the fonts smaller
Check this site - https://www.mrtechsonu.com/twitter-trending/
Hi there,
thats what happens if you load the bootstrap library its going to load a lot of styles ( in your case 7000 + Lines of CSS ) that will either not be required or create conflicts.
You should extract and load just the CSS styles you need for the tool you developed instead.
Is there any other option?
Like plugin or any other way?
What is it that requires Bootstrap ?
A popup needs bootstrap. You can go to the link I have provided, when tap on the Twitter hashtags a popup appears
That needs bootstrap to work
i can provide you the source code of that tool
Hi there,
The pop out seems involve quite a lot CSS from bootstrap.
I don't think there's an easy way out.
You might need to add more CSS to increase the font size to override the CSS added by bootstrap.
Is there any easy way to solve this?
Hi Sagar,
You can try adding/enqueueing just the CSS and JS for the pop out instead of the entire Bootstrap library. Then work through there.