S
S
smoklew2015-10-05 19:44:48
css
smoklew, 2015-10-05 19:44:48

What is the best way to type wrapper?

What is the best way to do layout?
Set the main container (wrapper) to ~ 980px wide and not bother with high resolutions, or make the elements width=100% and lay out 980px wide blocks in them?
Examples for understanding:
Fixed value: 1f1eabc3a7628d69e5e971edabd0fc78.pngStretches the background of elements across the entire window:
eb1f02d46448b0aaf1789f789edc6688.png

Answer the question

In order to leave comments, you need to log in

2 answer(s)
I
Ivanq, 2015-10-05
@Ivanq

It is better to set for the background width: 100%, but for content width: 70%or something like that. But this is my personal IMHO

V
Vitaly Inchin ☢, 2015-10-05
@In4in

I try to do like this:

.wrapper{
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

That is, on screens less than 1200px it will stretch, and on those that are larger it will simply be centered.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question