+ 1

How do I prevent my website from stretching horizontally??

I am making a website and in the background I want it to have some colored circles, but the problem is that if a circle leaves the visible area of ​​the website, the website stretches causing a horizontal scroll annoying and distorts the entire page.

16th Oct 2023, 8:05 PM
<YostDev>
<YostDev> - avatar
2 Réponses
+ 3
It is a little difficult to give a precise answer without seeing your code but you could start by adding overflow-x: hidden; to the CSS for the element containing the circles.
16th Oct 2023, 8:59 PM
Dan
0
Also you should add media queries to your code to make it responsive and use vw
17th Oct 2023, 6:01 PM
ADITYA MISHRA
ADITYA MISHRA - avatar